From ec7436e9be67c03be7f24b4e362db204c8d8315c Mon Sep 17 00:00:00 2001 From: Michael Groh Date: Thu, 4 Mar 2010 10:59:38 +0100 Subject: [PATCH] Adding users and changing passwords needs a configured core. Fixing bug #924 --- src/core/core.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/core/core.cpp b/src/core/core.cpp index 20049a8f..29174b62 100644 --- a/src/core/core.cpp +++ b/src/core/core.cpp @@ -875,7 +875,7 @@ void Core::createUser() { return; } - if(_storage->addUser(username, password).isValid()) { + if(_configured && _storage->addUser(username, password).isValid()) { out << "Added user " << username << " successfully!" << endl; } else { qWarning() << "Unable to add user:" << qPrintable(username); @@ -913,7 +913,7 @@ void Core::changeUserPass(const QString &username) { return; } - if(_storage->updateUser(userId, password)) { + if(_configured && _storage->updateUser(userId, password)) { out << "Password changed successfuly!" << endl; } else { qWarning() << "Failed to change password!"; -- 2.20.1