Skip to content

Commit 06db3f7

Browse files
authored
Update plyr.js
1 parent a2a82a9 commit 06db3f7

File tree

1 file changed

+4
-5
lines changed

1 file changed

+4
-5
lines changed

src/js/plyr.js

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -680,8 +680,7 @@ class Plyr {
680680
set quality(input) {
681681
const config = this.config.quality;
682682
const options = this.options.quality;
683-
const duration = this.duration;
684-
const isPlaying = this.playing;
683+
const { duration, playing } = this;
685684

686685
if (!options.length) {
687686
return;
@@ -706,11 +705,11 @@ class Plyr {
706705
// Set quality
707706
this.media.quality = quality;
708707

709-
// seek to duration before changing quality
708+
// Seek to duration before changing quality
710709
this.seek = duration;
711710

712-
// continue
713-
if (isPlaying) {
711+
// Continue
712+
if (playing) {
714713
this.play();
715714
}
716715
}

0 commit comments

Comments
 (0)