Correct checks for containers' emptiness

This commit is contained in:
Gianluca Recchia 2018-11-02 03:38:55 +01:00 committed by Jonathan White
parent fc930bae69
commit e81841550b
No known key found for this signature in database
GPG key ID: 440FC65F2E0C6E01
6 changed files with 9 additions and 8 deletions

View file

@ -220,7 +220,7 @@ void EntryPreviewWidget::updateEntryAttributesTab()
m_ui->entryAttributesEdit->clear();
const EntryAttributes* attributes = m_currentEntry->attributes();
const QStringList customAttributes = attributes->customKeys();
const bool haveAttributes = customAttributes.size() > 0;
const bool haveAttributes = !customAttributes.isEmpty();
setTabEnabled(m_ui->entryTabWidget, m_ui->entryAttributesTab, haveAttributes);
if (haveAttributes) {
QString attributesText;