diff --git a/src/utils/Player.js b/src/utils/Player.js index 3e315e0..98e6dc1 100644 --- a/src/utils/Player.js +++ b/src/utils/Player.js @@ -464,7 +464,11 @@ export default class { } } setOutputDevice() { - if (this._howler._sounds.length <= 0 || !this._howler._sounds[0]._node) { + if ( + process.env.IS_ELECTRON !== true || + this._howler._sounds.length <= 0 || + !this._howler._sounds[0]._node + ) { return; } this._howler._sounds[0]._node.setSinkId(store.state.settings.outputDevice); diff --git a/src/views/playlist.vue b/src/views/playlist.vue index a0aedc4..fe941ed 100644 --- a/src/views/playlist.vue +++ b/src/views/playlist.vue @@ -351,16 +351,20 @@ export default { filteredTracks() { return this.tracks.filter( (track) => - track.name - .toLowerCase() - .includes(this.searchKeyWords.toLowerCase()) || - track.al.name - .toLowerCase() - .includes(this.searchKeyWords.toLowerCase()) || - track.ar.find((artist) => - artist.name + (track.name && + track.name .toLowerCase() - .includes(this.searchKeyWords.toLowerCase()) + .includes(this.searchKeyWords.toLowerCase())) || + (track.al.name && + track.al.name + .toLowerCase() + .includes(this.searchKeyWords.toLowerCase())) || + track.ar.find( + (artist) => + artist.name && + artist.name + .toLowerCase() + .includes(this.searchKeyWords.toLowerCase()) ) ); },