mirror of
https://github.com/oxen-io/session-desktop.git
synced 2023-12-14 02:12:57 +01:00
Lint
This commit is contained in:
parent
d10a8f0a6f
commit
86b427cc4d
4 changed files with 19 additions and 9 deletions
14
app/base_config.d.ts
vendored
14
app/base_config.d.ts
vendored
|
@ -1,11 +1,15 @@
|
|||
export interface BaseConfig {
|
||||
set(keyPath: string, value: any): void
|
||||
get(keyPath: string): any | undefined
|
||||
remove(): void
|
||||
set(keyPath: string, value: any): void;
|
||||
get(keyPath: string): any | undefined;
|
||||
remove(): void;
|
||||
}
|
||||
|
||||
interface Options {
|
||||
allowMalformedOnStartup: boolean
|
||||
allowMalformedOnStartup: boolean;
|
||||
}
|
||||
|
||||
export function start(name: string, targetPath: string, options: Options): BaseConfig;
|
||||
export function start(
|
||||
name: string,
|
||||
targetPath: string,
|
||||
options: Options
|
||||
): BaseConfig;
|
||||
|
|
4
app/user_config.d.ts
vendored
4
app/user_config.d.ts
vendored
|
@ -1,3 +1,3 @@
|
|||
import { BaseConfig } from "./base_config";
|
||||
import { BaseConfig } from './base_config';
|
||||
|
||||
type UserConfig = BaseConfig
|
||||
type UserConfig = BaseConfig;
|
||||
|
|
|
@ -242,7 +242,8 @@ window.getMediaPermissions = () => ipc.sendSync('get-media-permissions');
|
|||
|
||||
// Auto update setting
|
||||
window.getAutoUpdateEnabled = () => ipc.sendSync('get-auto-update-enabled');
|
||||
window.setAutoUpdateEnabled = (value) => ipc.send('set-auto-update-enabled', !!value);
|
||||
window.setAutoUpdateEnabled = value =>
|
||||
ipc.send('set-auto-update-enabled', !!value);
|
||||
|
||||
ipc.on('get-ready-for-shutdown', async () => {
|
||||
const { shutdown } = window.Events || {};
|
||||
|
|
|
@ -3,7 +3,6 @@ import * as fs from 'fs-extra';
|
|||
import { autoUpdater, UpdateInfo } from 'electron-updater';
|
||||
import { app, BrowserWindow } from 'electron';
|
||||
import { markShouldQuit } from '../../app/window_state';
|
||||
import { UserConfig } from '../../app/user_config';
|
||||
|
||||
import {
|
||||
getPrintableError,
|
||||
|
@ -29,6 +28,12 @@ export async function start(
|
|||
messages: MessagesType,
|
||||
logger: LoggerType
|
||||
) {
|
||||
if (interval) {
|
||||
logger.info('auto-update: Already running');
|
||||
|
||||
return;
|
||||
}
|
||||
|
||||
logger.info('auto-update: starting checks...');
|
||||
|
||||
autoUpdater.logger = logger;
|
||||
|
|
Loading…
Reference in a new issue