Small mistakes.

This commit is contained in:
marley 2023-05-18 21:21:47 -07:00
parent 56cec7a835
commit 26234c2478
3 changed files with 4 additions and 6 deletions

View file

@ -29,7 +29,7 @@ export class Settings extends EventEmitter {
#matrixFile: null | string;
matrix?: EliteMatrix;
private constructor(isPackaged: boolean) {
private constructor() {
super();
this.#file = path.join(os.homedir(), 'ed-safari-settings.json');
@ -61,9 +61,9 @@ export class Settings extends EventEmitter {
}
}
static get(isPackaged: boolean = false): Settings {
static get(): Settings {
if (!Settings.#instance) {
Settings.#instance = new Settings(isPackaged);
Settings.#instance = new Settings();
}
return Settings.#instance;

View file

@ -4,7 +4,6 @@ import { Settings } from '../src/models/Settings';
import { mockSettings } from './mockData';
jest.mock('fs');
const fs = require('fs');
describe('Settings', () => {
const settingsFile = {

View file

@ -1,11 +1,10 @@
// noinspection DuplicatedCode
import { expect, jest, it, beforeEach } from '@jest/globals';
import { ExtendedNavRoute, FSDJump, Location } from '@kayahr/ed-journal';
import { FSDJump, Location } from '@kayahr/ed-journal';
import { Body } from '../src/models/Body';
import { CMDR } from '../src/models/CMDR';
import { EDSM } from '../src/models/EDSM';
import { Journal } from '../src/models/Journal';
import { ExtendedNavRouteSystem, System } from '../src/models/System';
import { mockEdsmResponses, mockObjects } from './mockData';