From 5b8721ff9286a5303219d39f7bf9efc8ca6b191a Mon Sep 17 00:00:00 2001 From: squidfunk Date: Fri, 17 Apr 2020 14:33:04 +0200 Subject: [PATCH] Fixed GitLab star count --- src/assets/javascripts/patches/source/index.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/assets/javascripts/patches/source/index.ts b/src/assets/javascripts/patches/source/index.ts index 935587daf..cf89a968d 100644 --- a/src/assets/javascripts/patches/source/index.ts +++ b/src/assets/javascripts/patches/source/index.ts @@ -74,8 +74,8 @@ function fetchSourceFacts( /* GitLab repository */ case "gitlab": - const [, base, project] = url.match(/^.+?([^\/]*gitlab[^\/]+)\/(.+)/i) - return fetchSourceFactsFromGitLab(base, project) + const [, base, slug] = url.match(/^.+?([^\/]*gitlab[^\/]+)\/(.+?)\/?$/i) + return fetchSourceFactsFromGitLab(base, slug) /* Everything else */ default: