Skip to content
This repository has been archived by the owner on Aug 22, 2023. It is now read-only.

Commit

Permalink
fix: do not require engine
Browse files Browse the repository at this point in the history
  • Loading branch information
jdx committed Jan 19, 2018
1 parent fcaa507 commit 937f136
Showing 1 changed file with 2 additions and 7 deletions.
9 changes: 2 additions & 7 deletions src/config.ts
Original file line number Diff line number Diff line change
Expand Up @@ -246,8 +246,8 @@ export class PluginConfig extends ConfigBase implements IPluginConfig {
}

export class CLIConfig extends ConfigBase implements ICLIConfig {
static async create({engine, name, root = __dirname}: ConfigOptions & {engine: IEngine}) {
const config = new this(engine)
static async create({name, root = __dirname}: ConfigOptions) {
const config = new this()
await config.load({name, root})
return config
}
Expand All @@ -257,11 +257,6 @@ export class CLIConfig extends ConfigBase implements ICLIConfig {
engine: IEngine
npmRegistry: string

constructor(engine: IEngine) {
super()
this.engine = engine
}

async load({root, name}: {root: string, name?: string}) {
await super.load({root, name})
this.npmRegistry = this.scopedEnvVar('NPM_REGISTRY') || this.pjson.dxcli.npmRegistry || 'https://registry.yarnpkg.com'
Expand Down

0 comments on commit 937f136

Please sign in to comment.