Fix mainnet daemon settings

This commit is contained in:
everoddandeven 2024-10-15 18:17:12 +02:00
parent 1ed45915e5
commit ab0c54c458

View file

@ -185,9 +185,11 @@ export class DaemonSettings {
const options: string[] = []; const options: string[] = [];
if (this.monerodPath != '') options.push(this.monerodPath); if (this.monerodPath != '') options.push(this.monerodPath);
if (this.mainnet) options.push(`--mainnet`); if (this.testnet) options.push(`--testnet`);
else if (this.testnet) options.push(`--testnet`);
else if (this.stagenet) options.push(`--stagenet`); else if (this.stagenet) options.push(`--stagenet`);
else if (!this.mainnet) {
throw new Error("Invalid daemon settings");
}
if (this.logFile != '') options.push('--log-file', this.logFile); if (this.logFile != '') options.push('--log-file', this.logFile);
if (this.logLevel >= 0 && this.logLevel <= 4) options.push('--log-level', `${this.logLevel}`); if (this.logLevel >= 0 && this.logLevel <= 4) options.push('--log-level', `${this.logLevel}`);