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

Fix models is undefined #12846

Closed
wants to merge 2 commits into from
Closed

Fix models is undefined #12846

wants to merge 2 commits into from

Conversation

mohlek
Copy link

@mohlek mohlek commented Jan 20, 2016

Fixes error when model is undefined
#12845

Fixes error when model is undefined
@@ -716,7 +716,7 @@ let LinkComponent = EmberComponent.extend({
}),

_modelsAreLoaded: computed('models', function computeLinkToComponentModelsAreLoaded() {
let models = get(this, 'models');
let models = get(this, 'models') | [];
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think you want to use bitwise OR.

@stefanpenner
Copy link
Member

this needs tests, and we need to see an example that illustrates this issue. I suspect it is an unrelated issue, and making this code defensive will merely hide the real issue.

added missing |
@homu
Copy link
Contributor

homu commented Apr 20, 2016

☔ The latest upstream changes (presumably #13381) made this pull request unmergeable. Please resolve the merge conflicts.

@locks
Copy link
Contributor

locks commented Jan 12, 2017

Hi @mohlek, I'm closing this as the component is now part of the ember-glimmer package. If you still intend to pursue this, please submit a follow up PR!

@locks locks closed this Jan 12, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants