diff --git a/src/screens/settings/ServerSettings.tsx b/src/screens/settings/ServerSettings.tsx index e68a855f..fe694c12 100644 --- a/src/screens/settings/ServerSettings.tsx +++ b/src/screens/settings/ServerSettings.tsx @@ -150,7 +150,7 @@ export const ServerSettings = () => { placeholder="https://github.com/MY_ACCOUNT/MY_REPO/tree/repo" validateItem={(repo) => !!repo.match( - /https:\/\/(?:www|raw)?(?:github|githubusercontent)\.com\/([^/]+)\/([^/]+)(?:\/(?:tree|blob)\/(.*))?\/?/g, + /https:\/\/(www\.|raw\.)?(github|githubusercontent)\.com\/([^/]+)\/([^/]+)((\/tree|\/blob)?\/([^/\n]*))?(\/([^/\n]*\.json)?)?/g, ) } invalidItemError={t('extension.settings.repositories.custom.error.label.invalid_url')}