SettingsAccessor: Support user file without EnvironmentId

Let the users forge a user file without injecting their environment.

Task-number: QTCREATORBUG-20097
Change-Id: Ia481f0f6d7c704d26b5f7d0f985f38dd39027f95
Reviewed-by: Tobias Hunger <tobias.hunger@qt.io>
This commit is contained in:
Orgad Shaneh
2018-04-08 12:07:56 +03:00
committed by Orgad Shaneh
parent e806ea40cc
commit 9053cd7515

View File

@@ -538,7 +538,7 @@ bool SettingsAccessor::isValidVersionAndId(const int version, const QByteArray &
const int lastVersion = currentVersion(); const int lastVersion = currentVersion();
return (version >= firstVersion && version <= lastVersion) return (version >= firstVersion && version <= lastVersion)
&& ( id == requiredId || requiredId.isEmpty()); && (id.isEmpty() || requiredId.isEmpty() || id == requiredId);
} }
/*! /*!