Fix GitLab bug that broke all repos with hyphens in their names (#2125)

This commit is contained in:
Imran Remtulla
2025-02-22 19:44:28 -05:00
parent a3c2761aba
commit 92ebbd9138

View File

@ -58,7 +58,7 @@ class GitLab extends AppSource {
url =
urlSegments.sublist(0, cutOffIndex <= 0 ? null : cutOffIndex).join('/');
RegExp standardUrlRegEx = RegExp(
'^https?://(www\\.)?${getSourceRegex(hosts)}/[^/]+(/[^/-]+){1,20}',
'^https?://(www\\.)?${getSourceRegex(hosts)}/[^/]+(/[^((\b/\b)|(\b/-/\b))]+){1,20}',
caseSensitive: false);
RegExpMatch? match = standardUrlRegEx.firstMatch(url);
if (match == null) {