From b08e4d193a2c6dea82a6f00432203cfad097e708 Mon Sep 17 00:00:00 2001 From: 0neGal Date: Fri, 21 Jul 2023 23:22:44 +0200 Subject: rename mods.list() properties to use snake case I may or may not have missed some properties or something somewhere, perhaps we'll see if something ends up broken in the future... --- src/app/main.js | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) (limited to 'src/app/main.js') diff --git a/src/app/main.js b/src/app/main.js index 1dbff40..26410cc 100644 --- a/src/app/main.js +++ b/src/app/main.js @@ -3,7 +3,12 @@ const path = require("path"); const { app, ipcRenderer, shell } = require("electron"); const lang = require("../lang"); -var modsobj = {}; +var modsobj = { + all: [], + enabled: [], + disabled: [] +} + let shouldInstallNorthstar = false; // Base settings @@ -212,11 +217,11 @@ function installFromURL(url, dependencies, clearqueue, author) { function isModInstalled(modname) { for (let i = 0; i < modsobj.all.length; i++) { let mod = modsobj.all[i]; - if (mod.ManifestName) { - if (mod.ManifestName.match(modname)) { + if (mod.manifest_name) { + if (mod.manifest_name.match(modname)) { return true; } - } else if (mod.Name.match(modname)) { + } else if (mod.name.match(modname)) { return true; } } -- cgit v1.2.3