This commit is contained in:
Mirco Wittrien 2021-05-03 16:37:43 +02:00
parent b40f9a030f
commit ae0fa08908
2 changed files with 4 additions and 4 deletions

View File

@ -134,8 +134,8 @@ module.exports = (_ => {
}
filterPlugins() {
let plugins = grabbedPlugins.map(plugin => {
const installedPlugin = plugin.version && _this.getInstalledPlugin(plugin);
const state = installedPlugin ? (BDFDB.NumberUtils.compareVersions(plugin.version, _this.getString(installedPlugin.version)) ? pluginStates.OUTDATED : pluginStates.INSTALLED) : pluginStates.DOWNLOADABLE;
const installedPlugin = _this.getInstalledPlugin(plugin);
const state = installedPlugin ? (plugin.version && BDFDB.NumberUtils.compareVersions(plugin.version, _this.getString(installedPlugin.version)) ? pluginStates.OUTDATED : pluginStates.INSTALLED) : pluginStates.DOWNLOADABLE;
return {
...plugin,
search: [plugin.name, plugin.version, plugin.author, plugin.description, plugin.tags].flat(10).filter(n => typeof n == "string").join(" ").toUpperCase(),

View File

@ -136,8 +136,8 @@ module.exports = (_ => {
}
filterThemes() {
let themes = grabbedThemes.map(theme => {
const installedTheme = theme.version && _this.getInstalledTheme(theme);
const state = installedTheme ? (BDFDB.NumberUtils.compareVersions(theme.version, _this.getString(installedTheme.version)) ? themeStates.OUTDATED : themeStates.INSTALLED) : themeStates.DOWNLOADABLE;
const installedTheme = _this.getInstalledTheme(theme);
const state = installedTheme ? (theme.version && BDFDB.NumberUtils.compareVersions(theme.version, _this.getString(installedTheme.version)) ? themeStates.OUTDATED : themeStates.INSTALLED) : themeStates.DOWNLOADABLE;
return {
...theme,
search: [theme.name, theme.version, theme.author, theme.description, theme.tags].flat(10).filter(n => typeof n == "string").join(" ").toUpperCase(),