Commit 7aedc83f authored by Laurent Montel's avatar Laurent Montel 😁
Browse files

Use hasChildren

parent 41cd5da1
......@@ -100,7 +100,7 @@ void FolderShortcutActionManager::updateShortcutsForIndex(const QModelIndex &par
if (collection.isValid()) {
shortcutChanged(collection);
}
if (model->rowCount(child) > 0) {
if (model->hasChildren(child)) {
updateShortcutsForIndex(child, 0, model->rowCount(child) - 1);
}
}
......
......@@ -97,7 +97,7 @@ void UnityServiceManager::unreadMail(const QAbstractItemModel *model, const QMod
}
}
}
if (model->rowCount(index) > 0) {
if (model->hasChildren(index)) {
unreadMail(model, index);
}
}
......
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