aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/assets/player/shared/common
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2022-10-12 16:09:02 +0200
committerChocobozzz <chocobozzz@cpy.re>2022-10-24 14:48:24 +0200
commit3545e72c686ff1725bbdfd8d16d693e2f4aa75a3 (patch)
treee7f1d12ef5dae1e1142c3a8d0b681c1dbbb0de10 /client/src/assets/player/shared/common
parent38a3ccc7f8ad0ea94362b58c732af7c387ab46be (diff)
downloadPeerTube-3545e72c686ff1725bbdfd8d16d693e2f4aa75a3.tar.gz
PeerTube-3545e72c686ff1725bbdfd8d16d693e2f4aa75a3.tar.zst
PeerTube-3545e72c686ff1725bbdfd8d16d693e2f4aa75a3.zip
Put private videos under a specific subdirectory
Diffstat (limited to 'client/src/assets/player/shared/common')
-rw-r--r--client/src/assets/player/shared/common/utils.ts8
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
55function isSameOrigin (current: string, target: string) {
56 return new URL(current).origin === new URL(target).origin
57}
58
55// --------------------------------------------------------------------------- 59// ---------------------------------------------------------------------------
56 60
57export { 61export {
@@ -60,5 +64,7 @@ export {
60 64
61 videoFileMaxByResolution, 65 videoFileMaxByResolution,
62 videoFileMinByResolution, 66 videoFileMinByResolution,
63 bytes 67 bytes,
68
69 isSameOrigin
64} 70}