Skip to content

Commit

Permalink
fix(@angular/cli): Fix parsing of new options
Browse files Browse the repository at this point in the history
fixes #10802
  • Loading branch information
Brocco committed May 17, 2018
1 parent 81393b7 commit 0820650
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions packages/@angular/cli/commands/new.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ export default class NewCommand extends SchematicCommand {
description: 'Schematics collection to use.'
}
];
private schematicName = 'ng-new';

private initialized = false;
public initialize(options: any) {
Expand All @@ -37,11 +38,10 @@ export default class NewCommand extends SchematicCommand {
this.initialized = true;

const collectionName = this.parseCollectionName(options);
const schematicName = 'application';

return this.getOptions({
schematicName,
collectionName
schematicName: this.schematicName,
collectionName,
})
.then((schematicOptions) => {
this.options = this.options.concat(schematicOptions.options);
Expand Down Expand Up @@ -75,7 +75,7 @@ export default class NewCommand extends SchematicCommand {

return this.runSchematic({
collectionName: collectionName,
schematicName: 'ng-new',
schematicName: this.schematicName,
schematicOptions: options,
debug: options.debug,
dryRun: options.dryRun,
Expand Down

0 comments on commit 0820650

Please sign in to comment.