Skip to content

Commit

Permalink
feat(spotify): add Accept-Language header to API requests
Browse files Browse the repository at this point in the history
  • Loading branch information
phts committed Sep 10, 2024
1 parent e93bfee commit 0e74743
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 1 deletion.
1 change: 1 addition & 0 deletions spotify/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -987,6 +987,7 @@ ControllerSpotify.prototype.spotifyApiConnect = function () {
var d = new Date();

self.spotifyApi = new SpotifyWebApi();
self.spotifyApi.setDefaultHeaders({'Accept-Language': self.commandRouter.sharedVars.get('language_code')});

// Retrieve an access token
self.spotifyClientCredentialsGrant()
Expand Down
2 changes: 1 addition & 1 deletion spotify/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@
"kew": "^0.7.0",
"node-cache": "^4.1.1",
"socket.io-client": "2.1.1",
"spotify-web-api-node": "^5.0.2",
"spotify-web-api-node": "volumio/spotify-web-api-node#cfe245456d46539a4d6022ad67b8607123f68399",
"superagent": "^8.1.2",
"v-conf": "^1.4.2",
"ws": "^8.13.0"
Expand Down

0 comments on commit 0e74743

Please sign in to comment.