mirror of
https://github.com/gristlabs/grist-core.git
synced 2026-03-02 04:09:24 +00:00
config: remove all async/await around config read functions
Now that reading is synchronous, there's no need to have any more async/await in regards to the those config functions.
This commit is contained in:
committed by
jordigh
parent
4013382170
commit
e30a090a4e
@@ -9,10 +9,10 @@ let cachedGlobalConfig: IGristCoreConfig | undefined = undefined;
|
||||
/**
|
||||
* Retrieves the cached grist config, or loads it from the default global path.
|
||||
*/
|
||||
export async function getGlobalConfig(): Promise<IGristCoreConfig> {
|
||||
export function getGlobalConfig(): IGristCoreConfig {
|
||||
if (!cachedGlobalConfig) {
|
||||
log.info(`Loading config file from ${globalConfigPath}`);
|
||||
cachedGlobalConfig = await loadGristCoreConfigFile(globalConfigPath);
|
||||
cachedGlobalConfig = loadGristCoreConfigFile(globalConfigPath);
|
||||
}
|
||||
|
||||
return cachedGlobalConfig;
|
||||
|
||||
Reference in New Issue
Block a user