Browse Source

Hopefully fixed bug where Please click anywhere would appear during playing video on station page

Kristian Vos 3 years ago
parent
commit
f0b2b62a6e
1 changed files with 2 additions and 1 deletions
  1. 2 1
      frontend/src/pages/Station/index.vue

+ 2 - 1
frontend/src/pages/Station/index.vue

@@ -1175,6 +1175,7 @@ export default {
 										this.currentSong.skipDuration,
 									true
 								);
+								this.canAutoplay = true;
 								if (this.localPaused || this.stationPaused)
 									this.player.pauseVideo();
 							} else if (
@@ -1251,7 +1252,7 @@ export default {
 				this.currentSong &&
 				this.player.getPlayerState() === -1
 			) {
-				if (this.attemptsToPlayVideo >= 5) {
+				if (!this.canAutoplay) {
 					if (
 						Date.now() - this.lastTimeRequestedIfCanAutoplay >
 						2000