add check for volume parameter in URL before setting volume (#372)

This commit is contained in:
FapFapDragon 2024-03-10 08:43:30 -04:00 committed by GitHub
parent 798bf579c0
commit db6f9c957e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -204,7 +204,9 @@
@Watch('volume', { immediate: true }) @Watch('volume', { immediate: true })
onVolume(volume: number) { onVolume(volume: number) {
this.$accessor.video.setVolume(volume) if (new URL(location.href).searchParams.has('volume')) {
this.$accessor.video.setVolume(volume)
}
} }
@Watch('hideControls', { immediate: true }) @Watch('hideControls', { immediate: true })