Commit 634ee75c authored by Aleix Pol Gonzalez's avatar Aleix Pol Gonzalez 🐧

Fix NetworkModel::rowCount when the parent is one of the list items

parent cda869c4
......@@ -117,7 +117,7 @@ QVariant NetworkModel::data(const QModelIndex& index, int role) const
int NetworkModel::rowCount(const QModelIndex& parent) const
{
Q_UNUSED(parent);
return m_list.count();
return parent.isValid() ? 0 : m_list.count();
}
QHash< int, QByteArray > NetworkModel::roleNames() const
......
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