Check empty string using .isEmpty() instead of == ""
This commit is contained in:
parent
c9d85107e6
commit
459a1992e5
2 changed files with 2 additions and 2 deletions
|
@ -53,7 +53,7 @@ void ConversationListModel::setDeviceId(const QString& deviceId)
|
|||
return;
|
||||
}
|
||||
|
||||
if (deviceId == "") {
|
||||
if (deviceId.isEmpty()) {
|
||||
return;
|
||||
}
|
||||
|
||||
|
|
|
@ -52,7 +52,7 @@ void ConversationModel::setThreadId(const qint64& threadId)
|
|||
m_threadId = threadId;
|
||||
clear();
|
||||
knownMessageIDs.clear();
|
||||
if (m_threadId != INVALID_THREAD_ID && m_deviceId != "") {
|
||||
if (m_threadId != INVALID_THREAD_ID && !m_deviceId.isEmpty()) {
|
||||
requestMoreMessages();
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue