From 2ed2207f4658c2affeb52aac981b2ac3249fae17 Mon Sep 17 00:00:00 2001 From: Karl Date: Mon, 9 Mar 2020 10:40:27 +0000 Subject: [PATCH] all working --- .vscode/launch.json | 9 +++++++++ player.js | 4 ---- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/.vscode/launch.json b/.vscode/launch.json index d7f63dd..a309818 100644 --- a/.vscode/launch.json +++ b/.vscode/launch.json @@ -31,6 +31,15 @@ "program": "${workspaceFolder}/player.js", "args":["url", "https://open.spotify.com/album/0sHibspyMdqOB4RsaCsG8X"] }, + { + "type": "node", + "request": "launch", + "name": "Player Pause", + "skipFiles": [ + ], + "program": "${workspaceFolder}/player.js", + "args":["pause"] + }, { "type": "node", "request": "launch", diff --git a/player.js b/player.js index 13a74a6..8b296f3 100644 --- a/player.js +++ b/player.js @@ -103,10 +103,8 @@ async function playFile() { let body; try { if (lastPlayer.includes(album)) { - console.log('same disk') body = {} } else { - console.log('different disk') body = { "context_uri": album, "offset": { @@ -132,12 +130,10 @@ async function playFile() { }, }); } catch (e) { - console.log('something went wrong') throw Error(`Request error: ${e}`); } this.response = response; this.response.body = response.body - console.log('all good') } async function playURL() {