Update SpotifyControls.plugin.js
This commit is contained in:
parent
298754d8b6
commit
13f7f75613
|
@ -83,7 +83,7 @@ module.exports = (_ => {
|
|||
authorization: `Bearer ${socket.accessToken}`
|
||||
}
|
||||
}, (error, response, result) => {
|
||||
if (response.statusCode == 401) {
|
||||
if (response && response.statusCode == 401) {
|
||||
BDFDB.LibraryModules.SpotifyUtils.getAccessToken(socket.accountId).then(promiseResult => {
|
||||
let newSocketDevice = BDFDB.LibraryModules.SpotifyTrackUtils.getActiveSocketAndDevice();
|
||||
this.request(newSocketDevice.socket, newSocketDevice.device, type, data).then(_ => {
|
||||
|
|
Loading…
Reference in New Issue