Browse Source

fixes in profile change and log password check

pull/423/head
apprb 11 years ago
parent
commit
08d7964dae
No known key found for this signature in database
GPG Key ID: B001911B5B22FB9B
  1. 1
      src/core.cpp
  2. 2
      src/historykeeper.cpp

1
src/core.cpp

@ -1263,6 +1263,7 @@ void Core::switchConfiguration(const QString& profile)
loadPath = QDir(Settings::getSettingsDirPath()).filePath(profile + TOX_EXT); loadPath = QDir(Settings::getSettingsDirPath()).filePath(profile + TOX_EXT);
Settings::getInstance().setCurrentProfile(profile); Settings::getInstance().setCurrentProfile(profile);
HistoryKeeper::getInstance()->resetInstance(); HistoryKeeper::getInstance()->resetInstance();
clearPassword();
start(); start();
} }

2
src/historykeeper.cpp

@ -67,7 +67,7 @@ bool HistoryKeeper::checkPassword()
{ {
if (Settings::getInstance().getEncryptLogs()) if (Settings::getInstance().getEncryptLogs())
{ {
QString dbpath = QDir(Settings::getInstance().getSettingsDirPath()).filePath("qtox_history.encrypted"); QString dbpath = getHistoryPath();
return EncryptedDb::check(dbpath); return EncryptedDb::check(dbpath);
} else { } else {
return true; return true;

Loading…
Cancel
Save