mirror of
https://github.com/logto-io/logto.git
synced 2024-12-30 20:33:54 -05:00
refactor(cli): use tryThat()
to enforce exit (#4267)
This commit is contained in:
parent
fde330a8b3
commit
2aeb575ccd
1 changed files with 2 additions and 2 deletions
|
@ -2,7 +2,7 @@ import { readFileSync, existsSync } from 'node:fs';
|
|||
import fs from 'node:fs/promises';
|
||||
import path from 'node:path';
|
||||
|
||||
import { trySafe } from '@silverhand/essentials';
|
||||
import { tryThat } from '@silverhand/essentials';
|
||||
import ts from 'typescript';
|
||||
|
||||
import { consoleLog } from '../../../utils.js';
|
||||
|
@ -312,7 +312,7 @@ export const syncPhraseKeysAndFileStructure = async (
|
|||
consoleLog.warn(`Cannot find ${targetLocale} entrypoint, creating one`);
|
||||
}
|
||||
|
||||
await trySafe(
|
||||
await tryThat(
|
||||
traverseNode(baseline, targetObject, path.join(targetDirectory, 'index.ts'), true),
|
||||
(error) => {
|
||||
consoleLog.plain();
|
||||
|
|
Loading…
Reference in a new issue