aboutsummaryrefslogtreecommitdiffhomepage
path: root/client/src/standalone/videos
diff options
context:
space:
mode:
authorChocobozzz <me@florianbigard.com>2018-06-07 15:03:33 +0200
committerChocobozzz <me@florianbigard.com>2018-06-07 15:03:33 +0200
commit46659d01dfd51a5ff3ca389978f8a0dda1d986d9 (patch)
tree6e720e842711a777c0aea89323d33d121c0e76ee /client/src/standalone/videos
parent3baf9be283d75cddc8aab918e6d6557371fbd9e9 (diff)
downloadPeerTube-46659d01dfd51a5ff3ca389978f8a0dda1d986d9.tar.gz
PeerTube-46659d01dfd51a5ff3ca389978f8a0dda1d986d9.tar.zst
PeerTube-46659d01dfd51a5ff3ca389978f8a0dda1d986d9.zip
Fix embed view with search params
Diffstat (limited to 'client/src/standalone/videos')
-rw-r--r--client/src/standalone/videos/embed.ts3
1 files changed, 2 insertions, 1 deletions
diff --git a/client/src/standalone/videos/embed.ts b/client/src/standalone/videos/embed.ts
index 166013226..4f6fae8aa 100644
--- a/client/src/standalone/videos/embed.ts
+++ b/client/src/standalone/videos/embed.ts
@@ -59,7 +59,8 @@ function videoFetchError (videoElement: HTMLVideoElement) {
59} 59}
60 60
61const urlParts = window.location.href.split('/') 61const urlParts = window.location.href.split('/')
62const videoId = urlParts[urlParts.length - 1] 62const lastPart = urlParts[urlParts.length - 1]
63const videoId = lastPart.indexOf('?') === -1 ? lastPart : lastPart.split('?')[0]
63 64
64loadLocale(environment.apiUrl, videojs, navigator.language) 65loadLocale(environment.apiUrl, videojs, navigator.language)
65 .then(() => loadVideoInfo(videoId)) 66 .then(() => loadVideoInfo(videoId))