diff --git a/public/src/js/plugins.js b/public/src/js/plugins.js index df0f983..1267226 100644 --- a/public/src/js/plugins.js +++ b/public/src/js/plugins.js @@ -151,6 +151,15 @@ class Plugins{ return input.slice(0, index) + insertedText + input.slice(index + searchString.length) } + hasSettings(){ + for(var i = 0; i < this.allPlugins.length; i++){ + var plugin = this.allPlugins[i].plugin + if(plugin.loaded && (!plugin.hide || plugin.settings())){ + return true + } + } + return false + } getSettings(){ var items = [] for(var i = 0; i < this.allPlugins.length; i++){ diff --git a/public/src/js/songselect.js b/public/src/js/songselect.js index 4caebeb..0352884 100644 --- a/public/src/js/songselect.js +++ b/public/src/js/songselect.js @@ -161,7 +161,7 @@ class SongSelect{ category: strings.random }) } - if(plugins.allPlugins.length){ + if(plugins.hasSettings()){ this.songs.push({ title: strings.plugins.title, skin: this.songSkin.plugins,