mirror of
https://github.com/MasterAcnolo/Freedom-Loader.git
synced 2026-07-29 18:25:47 +02:00
fix: move config to AppData to prevent settings loss on update, add config.dev.json for dev environment
This commit is contained in:
@@ -1,18 +1,10 @@
|
||||
const { ipcMain, dialog, shell } = require("electron");
|
||||
const fs = require("fs");
|
||||
const path = require("path");
|
||||
const { logger, logDir } = require("../server/logger");
|
||||
const { configFeatures } = require("../config");
|
||||
const { configFeatures, featuresPath } = require("../config");
|
||||
const config = require("../config");
|
||||
const { validateDownloadPath, getDefaultDownloadPath } = require("./pathValidator");
|
||||
|
||||
const configFolderPath = path.join(
|
||||
config.localMode
|
||||
|
||||
? path.join(__dirname, "..")
|
||||
: path.join(path.dirname(process.execPath), "resources"), "config", "config.json"
|
||||
);
|
||||
|
||||
const FEATURE_WHITELIST = new Set([
|
||||
"autoUpdate",
|
||||
"discordRPC",
|
||||
@@ -25,6 +17,8 @@ const FEATURE_WHITELIST = new Set([
|
||||
"customCodec",
|
||||
]);
|
||||
|
||||
const configFolderPath = featuresPath;
|
||||
|
||||
function registerIpcHandlers(getMainWindow) {
|
||||
|
||||
// Infos générales
|
||||
|
||||
Reference in New Issue
Block a user