Skip to content

Commit a83eea5

Browse files
committed
Better error messages
1 parent 1b7e86a commit a83eea5

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

src/index/multi_index.cpp

+4-1
Original file line numberDiff line numberDiff line change
@@ -60,12 +60,15 @@ QSharedPointer<Index> MultiIndex::getIndex(const QString &name, bool create) {
6060
}
6161

6262
void MultiIndex::createIndex(const QString &name) {
63+
if (name == ROOT_INDEX_NAME) {
64+
throw NotImplemented("Changing the legacy root index is not supported");
65+
}
6366
getIndex(name, true);
6467
}
6568

6669
void MultiIndex::deleteIndex(const QString &name) {
6770
if (name == ROOT_INDEX_NAME) {
68-
throw NotImplemented("Index deletion is not supported");
71+
throw NotImplemented("Changing the legacy root index is not supported");
6972
}
7073
QMutexLocker locker(&m_mutex);
7174
m_indexes.remove(name);

0 commit comments

Comments
 (0)