1
0
mirror of https://github.com/qTox/qTox.git synced 2024-03-22 14:00:36 +08:00

Merge pull request #3172

Impyy (1):
      fix(profile): Don't require .ini to load profile
This commit is contained in:
sudden6 2016-04-23 12:28:27 +02:00
commit 56e59d0fa3
No known key found for this signature in database
GPG Key ID: 279509B499E032B9

View File

@ -202,17 +202,11 @@ void Profile::scanProfiles()
for (QString toxfile : toxfiles)
{
if (!inifiles.contains(toxfile))
importProfile(toxfile);
Settings::getInstance().createPersonal(toxfile);
profiles.append(toxfile);
}
}
void Profile::importProfile(QString name)
{
assert(!exists(name));
Settings::getInstance().createPersonal(name);
}
QVector<QString> Profile::getProfiles()
{
return profiles;
@ -464,7 +458,7 @@ void Profile::removeAvatar(const QString &ownerId)
bool Profile::exists(QString name)
{
QString path = Settings::getInstance().getSettingsDirPath() + name;
return QFile::exists(path+".tox") && QFile::exists(path+".ini");
return QFile::exists(path+".tox");
}
bool Profile::isEncrypted() const