1
0
Fork 0
mirror of https://github.com/portainer/portainer.git synced 2025-08-10 00:05:24 +02:00

fix(webhook) remove NaN fom webhook url EE-5373 (#8815)

This commit is contained in:
cmeng 2023-04-21 10:56:59 +12:00 committed by GitHub
parent fee315b07e
commit 535e499cc5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -42,7 +42,8 @@ function getBaseUrl() {
const port = parseInt(window.location.port, 10);
const displayPort =
(protocol === 'http' && port === 80) ||
(protocol === 'https' && port === 443)
(protocol === 'https' && port === 443) ||
Number.isNaN(port)
? ''
: `:${port}`;
return `${protocol}://${hostname}${displayPort}${baseHref()}`;