-
Notifications
You must be signed in to change notification settings - Fork 24
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
adcfe5a
commit e4045e7
Showing
2 changed files
with
135 additions
and
135 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,15 @@ | ||
import { TuonoConfig } from '../config' | ||
|
||
export const loadConfig = async (): Promise<TuonoConfig> => { | ||
try { | ||
return await import(`${process.cwd()}/.tuono/config/config.js`) | ||
} catch { | ||
return {} | ||
} | ||
try { | ||
return await import(`${process.cwd()}/.tuono/config/config.js`) | ||
} catch { | ||
return {} | ||
} | ||
} | ||
|
||
export const blockingAsync = (callback: () => Promise<void>) => { | ||
; (async () => { | ||
await callback() | ||
})() | ||
;(async () => { | ||
await callback() | ||
})() | ||
} |