content: exlcude links to localhost
ci/woodpecker/pr/woodpecker Pipeline was successful Details
ci/woodpecker/push/woodpecker Pipeline was successful Details

No good reason to link to localhost.
pull/53/head
OFF0 1 year ago
parent dc664fc318
commit d7f75f92e0
Signed by: offbyn
GPG Key ID: 94A2F643C51F37FA

@ -31,6 +31,9 @@ function isValidURL(url) {
if (!['', '443', '80'].includes(url.port)) {
return false;
}
if (url.hostname === 'localhost') {
return false;
}
const lastDot = url.hostname.lastIndexOf('.');
if (lastDot < 1) {
return false;

Loading…
Cancel
Save