summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMontel Laurent <montel@kde.org>2016-11-12 15:05:16 (GMT)
committerMontel Laurent <montel@kde.org>2016-11-12 15:05:16 (GMT)
commite6c9bf03e4bbbc81debf61353ed0501d6ae5de52 (patch)
treec903b153b865c12927a037fff98bb69ffd020cf2
parentbf9ab4022dcdb3648b17e0bc68dcfb22286a0c17 (diff)
Use isEmpty
-rw-r--r--resources/imap/setupserver.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/resources/imap/setupserver.cpp b/resources/imap/setupserver.cpp
index f2a2d91..8c919d7 100644
--- a/resources/imap/setupserver.cpp
+++ b/resources/imap/setupserver.cpp
@@ -603,10 +603,10 @@ void SetupServer::slotSafetyChanged()
foreach (int prot, protocols) {
addAuthenticationItem(m_ui->authenticationCombo, (MailTransport::Transport::EnumAuthenticationType::type) prot);
}
- if (protocols.size() > 0) {
- setCurrentAuthMode(m_ui->authenticationCombo, (MailTransport::Transport::EnumAuthenticationType::type) protocols.first());
- } else {
+ if (protocols.isEmpty()) {
qCDebug(IMAPRESOURCE_LOG) << "no authmodes found";
+ } else {
+ setCurrentAuthMode(m_ui->authenticationCombo, (MailTransport::Transport::EnumAuthenticationType::type) protocols.first());
}
}