From 7d26f3351ff03e742212eebb5eaf266a9a3a3bfc Mon Sep 17 00:00:00 2001 From: Carl Schwan Date: Tue, 20 Feb 2024 12:33:36 +0100 Subject: [PATCH] Fix crash in RoomTreeModel --- src/models/roomtreemodel.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/models/roomtreemodel.cpp b/src/models/roomtreemodel.cpp index 65c539a00..f88e244d5 100644 --- a/src/models/roomtreemodel.cpp +++ b/src/models/roomtreemodel.cpp @@ -231,7 +231,7 @@ QHash RoomTreeModel::roleNames() const // TODO room type changes QVariant RoomTreeModel::data(const QModelIndex &index, int role) const { - if (!index.isValid()) { + if (!checkIndex(index, QAbstractItemModel::CheckIndexOption::IndexIsValid)) { return QVariant(); }