Skip to content

#588 - octane - guides update - model/relationships - #634

Merged
jenweber merged 2 commits into
ember-learn:octanefrom
dennismende:octane-ember-data-guides-review-relationships
Apr 6, 2019
Merged

jenweber merged 2 commits into
ember-learn:octanefrom
dennismende:octane-ember-data-guides-review-relationships

Conversation

@dennismende

@dennismende dennismende commented Mar 17, 2019 •

Copy link
Copy Markdown

No description provided.

@dennismende

Copy link
Copy Markdown
Author

removed computed and make use of getter to stick to decisions made in #543 and #553

@locks

locks commented Mar 17, 2019

Copy link
Copy Markdown
Contributor

Hm, I believe these should be tracked properties, otherwise it won't update? cc @pzuraq

@mixonic

mixonic commented Mar 18, 2019

Copy link
Copy Markdown
Contributor

I think @pzuraq was suggesting this very change in #553 (comment).

@pzuraq

pzuraq commented Mar 18, 2019

Copy link
Copy Markdown
Contributor

Yup! So, @attr is a computed property, which means that when it is encountered by the autotracker it will be autotracked. So we can convert any CPs that rely on that property to standard getters instead 😄 any non @attrs/computeds do still need to be converted to tracked properties, but that doesn't apply in this case

@jamescdavis jamescdavis left a comment •

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Also in PaymentPethodPaypal, but github won't let me comment on that line.

obfuscatedIdentifier: computed('last4', function () {
get obfuscatedIdentifier() {
return `**** **** **** ${this.last4}`;
})

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

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

Suggested change
})
}

@jenweber

Copy link
Copy Markdown
Contributor

@dennismende Could you make the two punctuation fixes noted by James (}) should be ) in two places)? Then this will be good to merge!

It is helpful if you check "allow maintainers to make changes" when you open PRs, if you are ok with it. It's not required, but it means we can do things like update stale branches or fix small typos without bugging you about it. Thanks for the help!

@jenweber

jenweber commented Apr 6, 2019

Copy link
Copy Markdown
Contributor

I pulled these commits by @dennismende into a fresh PR, and then made the typo fixes. It's been merged! Thanks Dennis for your help!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants