small fix

This commit is contained in:
arcan1s
2014-07-20 12:47:43 +04:00
parent 43de4e5738
commit 32683a89b9
5 changed files with 9 additions and 9 deletions

View File

@ -144,7 +144,7 @@ QString Netctl::getWifiInterface()
interfaces.append(allInterfaces[i]);
}
if (interfaces.count() == 0)
if (interfaces.isEmpty())
return QString("");
else
return interfaces[0];

View File

@ -287,7 +287,7 @@ bool WpaSup::startWpaSupplicant()
if (debug) qDebug() << "[WpaSup]" << "[startWpaSupplicant]" << ":" << "Could not find wpa_supplicant";
return false;
}
if (getInterfaceList().count() == 0) {
if (getInterfaceList().isEmpty()) {
if (debug) qDebug() << "[WpaSup]" << "[startWpaSupplicant]" << ":" << "Could not find interfaces";
return false;
}
@ -343,7 +343,7 @@ QString WpaSup::getWpaCliOutput(const QString commandLine)
if (debug) qDebug() << "[WpaSup]" << "[getWpaCliOutput]" << ":" << "Could not find wpa_cli";
return QString();
}
if (getInterfaceList().count() == 0) {
if (getInterfaceList().isEmpty()) {
if (debug) qDebug() << "[WpaSup]" << "[getWpaCliOutput]" << ":" << "Could not find interfaces";
return QString();
}
@ -379,9 +379,9 @@ bool WpaSup::wpaCliCall(const QString commandLine)
if (debug) qDebug() << "[WpaSup]" << "[wpaCliCall]" << ":" << "Could not find wpa_cli";
return false;
}
if (getInterfaceList().count() == 0) {
if (getInterfaceList().isEmpty()) {
if (debug) qDebug() << "[WpaSup]" << "[wpaCliCall]" << ":" << "Could not find interfaces";
return QString();
return false;
}
QProcess command;