Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Small bug: "Cannot read property '0' of null" #12950

Closed
DmitriyIvanko opened this issue Nov 13, 2018 · 1 comment · Fixed by #12953
Closed

Small bug: "Cannot read property '0' of null" #12950

DmitriyIvanko opened this issue Nov 13, 2018 · 1 comment · Fixed by #12953
Labels
area: schematics/angular freq1: low Only reported by a handful of users who observe it rarely severity3: broken type: bug/fix
Milestone

Comments

@DmitriyIvanko
Copy link

Bug Report or Feature Request (mark with an x)

- [x] bug report -> please search issues before submitting
- [ ] feature request

Command (mark with an x)

- [ ] new
- [ ] build
- [ ] serve
- [ ] test
- [ ] e2e
- [x] generate
- [ ] add
- [ ] update
- [ ] lint
- [ ] xi18n
- [ ] run
- [ ] config
- [ ] help
- [ ] version
- [ ] doc

Versions

Node,js 8.11.4
npm 5.6.0
Angular: 7.0.3

Repro steps

  1. Generate new project ("Tour of Heroes: for example);
  2. Remove leading whitespaces in AppModule declaretions:
    screenshot_3
  3. Try add any component: "ng g c foobar"

The log given by the failure

Console throw an error:
"Cannot read property '0' of null"

Desired functionality

No error;

Mention any other details that might be useful

It is easy reproduce for any Angular ClL Project. Like Quickstart example:
https://angular.io/guide/quickstart

@alan-agius4 alan-agius4 added type: bug/fix freq1: low Only reported by a handful of users who observe it rarely severity3: broken area: schematics/angular labels Nov 13, 2018
@ngbot ngbot bot added this to the Backlog milestone Nov 13, 2018
kyliau pushed a commit that referenced this issue Nov 14, 2018
…out indent

At the moment, at least a single whitespace is required as otherwise the following error `Cannot read property '0' of null ` will be thrown

Fixes #12950
kyliau pushed a commit to kyliau/angular-cli that referenced this issue Nov 14, 2018
…out indent

At the moment, at least a single whitespace is required as otherwise the following error `Cannot read property '0' of null ` will be thrown

Fixes angular#12950
@angular-automatic-lock-bot
Copy link

This issue has been automatically locked due to inactivity.
Please file a new issue if you are encountering a similar or related problem.

Read more about our automatic conversation locking policy.

This action has been performed automatically by a bot.

@angular-automatic-lock-bot angular-automatic-lock-bot bot locked and limited conversation to collaborators Sep 8, 2019
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
area: schematics/angular freq1: low Only reported by a handful of users who observe it rarely severity3: broken type: bug/fix
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants