fix: search bug when searching in playlist (#495)

This commit is contained in:
Vidocq 2021-03-29 11:52:20 +08:00 committed by GitHub
parent d9c8489c92
commit 025e28399e
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
2 changed files with 18 additions and 10 deletions

View file

@ -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);