diff options
Diffstat (limited to 'packages/main/src/reactions/synchronizeConfig.ts')
-rw-r--r-- | packages/main/src/reactions/synchronizeConfig.ts | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/packages/main/src/reactions/synchronizeConfig.ts b/packages/main/src/reactions/synchronizeConfig.ts index 9436c16..adbe712 100644 --- a/packages/main/src/reactions/synchronizeConfig.ts +++ b/packages/main/src/reactions/synchronizeConfig.ts | |||
@@ -21,7 +21,6 @@ | |||
21 | import deepEqual from 'deep-equal'; | 21 | import deepEqual from 'deep-equal'; |
22 | import { debounce } from 'lodash-es'; | 22 | import { debounce } from 'lodash-es'; |
23 | import { reaction } from 'mobx'; | 23 | import { reaction } from 'mobx'; |
24 | import ms from 'ms'; | ||
25 | 24 | ||
26 | import type ConfigRepository from '../infrastructure/config/ConfigRepository'; | 25 | import type ConfigRepository from '../infrastructure/config/ConfigRepository'; |
27 | import type SharedStore from '../stores/SharedStore'; | 26 | import type SharedStore from '../stores/SharedStore'; |
@@ -29,14 +28,14 @@ import type Config from '../stores/config/Config'; | |||
29 | import type Disposer from '../utils/Disposer'; | 28 | import type Disposer from '../utils/Disposer'; |
30 | import { getLogger } from '../utils/log'; | 29 | import { getLogger } from '../utils/log'; |
31 | 30 | ||
32 | const DEFAULT_CONFIG_DEBOUNCE_TIME = ms('1s'); | 31 | const DEFAULT_CONFIG_DEBOUNCE_TIME_MS = 1000; |
33 | 32 | ||
34 | const log = getLogger('synchronizeConfig'); | 33 | const log = getLogger('synchronizeConfig'); |
35 | 34 | ||
36 | export default async function synchronizeConfig( | 35 | export default async function synchronizeConfig( |
37 | sharedStore: SharedStore, | 36 | sharedStore: SharedStore, |
38 | repository: ConfigRepository, | 37 | repository: ConfigRepository, |
39 | debounceTime: number = DEFAULT_CONFIG_DEBOUNCE_TIME, | 38 | debounceTime: number = DEFAULT_CONFIG_DEBOUNCE_TIME_MS, |
40 | ): Promise<Disposer> { | 39 | ): Promise<Disposer> { |
41 | let lastConfigOnDisk: Config | undefined; | 40 | let lastConfigOnDisk: Config | undefined; |
42 | 41 | ||