Commit e59b94f0 authored by Albert Vaca Cintora's avatar Albert Vaca Cintora

Simplified unpair logic

parent 161ec366
......@@ -164,16 +164,13 @@ void Device::unpair()
if (!isPaired()) return;
m_pairStatus = NotPaired;
pairingTimer.stop();
KSharedConfigPtr config = KSharedConfig::openConfig("kdeconnectrc");
config->group("trusted_devices").deleteGroup(id());
if (isReachable()) {
NetworkPackage np(PACKAGE_TYPE_PAIR);
np.set("pair", false);
sendPackage(np);
}
NetworkPackage np(PACKAGE_TYPE_PAIR);
np.set("pair", false);
sendPackage(np);
reloadPlugins(); //Will unload the plugins
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment