diff options
Diffstat (limited to 'src/js/plyr.js')
-rw-r--r-- | src/js/plyr.js | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/src/js/plyr.js b/src/js/plyr.js index c2bb6a4d..374251e6 100644 --- a/src/js/plyr.js +++ b/src/js/plyr.js @@ -553,7 +553,7 @@ class Plyr { */ increaseVolume(step) { const volume = this.media.muted ? 0 : this.volume; - this.volume = volume + (is.number(step) ? step : 1); + this.volume = volume + (is.number(step) ? step : 0); } /** @@ -561,8 +561,7 @@ class Plyr { * @param {boolean} step - How much to decrease by (between 0 and 1) */ decreaseVolume(step) { - const volume = this.media.muted ? 0 : this.volume; - this.volume = volume - (is.number(step) ? step : 1); + this.increaseVolume(-step); } /** |