diff options
Diffstat (limited to 'client/src/assets/player/shared/common/utils.ts')
-rw-r--r-- | client/src/assets/player/shared/common/utils.ts | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/client/src/assets/player/shared/common/utils.ts b/client/src/assets/player/shared/common/utils.ts index a010d9184..609240626 100644 --- a/client/src/assets/player/shared/common/utils.ts +++ b/client/src/assets/player/shared/common/utils.ts | |||
@@ -52,6 +52,10 @@ function getRtcConfig () { | |||
52 | } | 52 | } |
53 | } | 53 | } |
54 | 54 | ||
55 | function isSameOrigin (current: string, target: string) { | ||
56 | return new URL(current).origin === new URL(target).origin | ||
57 | } | ||
58 | |||
55 | // --------------------------------------------------------------------------- | 59 | // --------------------------------------------------------------------------- |
56 | 60 | ||
57 | export { | 61 | export { |
@@ -60,5 +64,7 @@ export { | |||
60 | 64 | ||
61 | videoFileMaxByResolution, | 65 | videoFileMaxByResolution, |
62 | videoFileMinByResolution, | 66 | videoFileMinByResolution, |
63 | bytes | 67 | bytes, |
68 | |||
69 | isSameOrigin | ||
64 | } | 70 | } |