Skip to content

Commit

Permalink
fix(spotify): clean up unused files and variables
Browse files Browse the repository at this point in the history
  • Loading branch information
phts committed Jan 8, 2024
1 parent f4f5d1d commit 4bec3e6
Show file tree
Hide file tree
Showing 3 changed files with 1 addition and 22 deletions.
16 changes: 1 addition & 15 deletions spotify/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -2,29 +2,20 @@

var libQ = require('kew');
var fs = require('fs-extra');
var config = new (require('v-conf'))();
var superagent = require('superagent');
var os = require('os');
var websocket = require('ws');
var path = require('path');
var SpotifyWebApi = require('spotify-web-api-node');
var io = require('socket.io-client');
var exec = require('child_process').exec;
var execSync = require('child_process').execSync;
var NodeCache = require('node-cache');
var os = require('os');
var { fetchPagedData, rateLimitedCall } = require('./utils/extendedSpotifyApi');

var configFileDestinationPath = '/tmp/go-librespot-config.yml';
var credentialsPath = '/data/configuration/music_service/spop/spotifycredentials.json';
var spotifyDaemonPort = '9879';
var spotifyLocalApiEndpointBase = 'http://127.0.0.1:' + spotifyDaemonPort;
var stateSocket = undefined;

var selectedBitrate;
var loggedInUsername;
var loggedInUserId;
var userCountry;
var seekTimer;
var restartTimeout;
var wsConnectionStatus = 'started';
Expand Down Expand Up @@ -791,15 +782,10 @@ ControllerSpotify.prototype.isOauthLoginAlreadyConfiguredOnDaemon = function ()
}
};

ControllerSpotify.prototype.saveGoLibrespotSettings = function (data, avoidBroadcastUiConfig) {
ControllerSpotify.prototype.saveGoLibrespotSettings = function (data) {
var self = this;
var defer = libQ.defer();

var broadcastUiConfig = true;
if (avoidBroadcastUiConfig === true){
broadcastUiConfig = false;
}

if (data.bitrate !== undefined && data.bitrate.value !== undefined) {
self.config.set('bitrate_number', data.bitrate.value);
}
Expand Down
3 changes: 0 additions & 3 deletions spotify/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,9 +8,6 @@
},
"author": "Ashthespy, Balbuze, Skirkwood",
"license": "ISC",
"vollibrespot": {
"version": "0.2.5"
},
"volumio_info": {
"prettyName": "Spotify",
"icon": "fa-spotify",
Expand Down
4 changes: 0 additions & 4 deletions spotify/startconnect.sh

This file was deleted.

0 comments on commit 4bec3e6

Please sign in to comment.