Skip to content

Commit

Permalink
Merge pull request #815 from Scrumplex/fix-funny
Browse files Browse the repository at this point in the history
  • Loading branch information
Scrumplex committed Feb 3, 2023
1 parent 104c231 commit 39bba9c
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion launcher/minecraft/OneSixVersionFormat.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -123,7 +123,7 @@ VersionFilePtr OneSixVersionFormat::versionFileFromJson(const QJsonDocument &doc
out->uid = root.value("fileId").toString();
}

const QRegularExpression valid_uid_regex{ QRegularExpression::anchoredPattern(QStringLiteral(R"(\w+(?:\.\w+)*)")) };
const QRegularExpression valid_uid_regex{ QRegularExpression::anchoredPattern(QStringLiteral(R"([a-zA-Z0-9-_]+(?:\.[a-zA-Z0-9-_]+)*)")) };
if (!valid_uid_regex.match(out->uid).hasMatch()) {
qCritical() << "The component's 'uid' contains illegal characters! UID:" << out->uid;
out->addProblem(
Expand Down

0 comments on commit 39bba9c

Please sign in to comment.