]> git.immae.eu Git - github/Chocobozzz/PeerTube.git/commitdiff
Fix resume video after peertube embed link click
authorChocobozzz <me@florianbigard.com>
Wed, 30 May 2018 08:49:27 +0000 (10:49 +0200)
committerChocobozzz <me@florianbigard.com>
Wed, 30 May 2018 08:49:27 +0000 (10:49 +0200)
client/src/assets/player/peertube-link-button.ts

index a47adc2dba5e928fcbeabe1a84515c3221eac2ea..54d802732573d0fdde2a17f9ad99facd2b4472c4 100644 (file)
@@ -32,7 +32,10 @@ class PeerTubeLinkButton extends Button {
 
   private buildHref (time?: number) {
     let href = window.location.href.replace('embed', 'watch')
-    if (time) href += '?start=' + time
+    if (time) {
+      if (window.location.search) href += '&start=' + time
+      else href += '?start=' + time
+    }
 
     return href
   }