fixed volume condition (last commit broke it)

This commit is contained in:
Jason Chen 2022-01-19 20:47:27 -08:00
parent dea8d1528a
commit a23bb9a6a5
3 changed files with 10 additions and 9 deletions

View file

@ -709,10 +709,6 @@ const app = new Vue({
this.mk.addEventListener(MusicKit.Events.playbackVolumeDidChange, (_a) => {
if( this.cfg.audio.muted && this.cfg.audio.lastVolume != 0 ) {
this.cfg.audio.muted = false;
this.cfg.audio.lastVolume = 0;
}
this.cfg.audio.volume = this.mk.volume
})
@ -3013,7 +3009,6 @@ const app = new Vue({
muteButtonPressed() {
if( this.cfg.audio.muted ) {
this.mk.volume = this.cfg.audio.lastVolume;
this.cfg.lastVolume = 0;
this.cfg.audio.muted = false;
} else {
this.cfg.audio.lastVolume = this.cfg.audio.volume;
@ -3021,7 +3016,11 @@ const app = new Vue({
this.cfg.audio.muted = true;
}
},
checkMuteChange() {
if( this.cfg.audio.muted ) {
this.cfg.audio.muted = false;
}
},
async apiCall(url, callback) {
const xmlHttp = new XMLHttpRequest();