Skip to content

Commit 415b877

Browse files
authored
fix(cli): do not use built in fetch (#2341)
1 parent 366ef79 commit 415b877

File tree

1 file changed

+4
-2
lines changed

1 file changed

+4
-2
lines changed

packages/cli/src/cli/config/action.import.ts

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@ import { BaseConfig, Config, ConfigBundle, ConfigBundled, ConfigProviderMemory }
33
import { CommandLineAction, CommandLineFlagParameter, CommandLineStringParameter } from '@rushstack/ts-command-line';
44
import { Q, Updater } from './config.update.js';
55
import { invalidateCache } from '../util.js';
6+
import fetch from 'node-fetch';
67

78
export class CommandImport extends CommandLineAction {
89
private config: CommandLineStringParameter;
@@ -49,8 +50,9 @@ export class CommandImport extends CommandLineAction {
4950
const config = this.config.value;
5051
const backup = this.backup.value;
5152
if (config == null) throw new Error('Please provide a config json');
52-
if (commit && !config.startsWith('s3://'))
53-
throw new Error('To acturally import into dynamo has to use the config file from s3.');
53+
if (commit && !config.startsWith('s3://')) {
54+
throw new Error('To actually import into dynamo has to use the config file from s3.');
55+
}
5456

5557
const HostPrefix = Env.isProduction() ? '' : 'dev.';
5658
const healthEndpoint = `https://${HostPrefix}basemaps.linz.govt.nz/v1/health`;

0 commit comments

Comments
 (0)