Skip to content

Commit

Permalink
fix: fix regex for internal url to use a more effecient one
Browse files Browse the repository at this point in the history
  • Loading branch information
Fallenbagel committed Jun 11, 2023
1 parent 0a30cd3 commit e848386
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/components/Settings/SettingsJellyfin.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -91,7 +91,7 @@ const SettingsJellyfin: React.FC<SettingsJellyfinProps> = ({
intl.formatMessage(messages.validationUrl)
),
jellyfinInternalUrl: Yup.string().matches(
/^(?:(?:(?:https?):)?\/\/)(?:\S+(?::\S*)?@)?(?:(?:[1-9]\d?|1\d\d|2[01]\d|22[0-3])(?:\.(?:1?\d{1,2}|2[0-4]\d|25[0-5])){2}(?:\.(?:[1-9]\d?|1\d\d|2[0-4]\d|25[0-4]))|(?:(?:[a-z\u00a1-\uffff0-9]-*)*[a-z\u00a1-\uffff0-9]+)(?:\.(?:[a-z\u00a1-\uffff0-9]-*)*[a-z\u00a1-\uffff0-9]+)*\.?)(?::\d{2,5})?(?:[/?#]\S*)?$/,
/^(https?:\/\/)?(?:[\w-]+\.)*[\w-]+(?::\d{2,5})?(?:\/[\w-]+)*(?:\/)?$/gm,
intl.formatMessage(messages.validationUrl)
),
});
Expand Down

0 comments on commit e848386

Please sign in to comment.