forked from qt-creator/qt-creator
ProjectExplorer: Check before setting errorMessage
Change-Id: Ic9437c3527f4f26bf72c5f7d18fdbde1217f4dd4 Reviewed-by: Tim Jenssen <tim.jenssen@qt.io>
This commit is contained in:
committed by
Tim Jenssen
parent
5bd68d6773
commit
b31c408c87
@@ -164,8 +164,10 @@ QVector<JsonKitsPage::ConditionalFeature> JsonKitsPage::parseFeatures(const QVar
|
||||
const QVariantMap obj = element.toMap();
|
||||
const QString feature = obj.value(QLatin1String(KEY_FEATURE)).toString();
|
||||
if (feature.isEmpty()) {
|
||||
*errorMessage = tr("No \"%1\" key found in feature list object.")
|
||||
.arg(QLatin1String(KEY_FEATURE));
|
||||
if (errorMessage) {
|
||||
*errorMessage = tr("No \"%1\" key found in feature list object.")
|
||||
.arg(QLatin1String(KEY_FEATURE));
|
||||
}
|
||||
return QVector<ConditionalFeature>();
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user