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

Update deprecate arguments #4760

Merged
merged 2 commits into from
Jan 23, 2017
Merged

Update deprecate arguments #4760

merged 2 commits into from
Jan 23, 2017

Conversation

estshy
Copy link
Contributor

@estshy estshy commented Jan 18, 2017

According to docs (https://github.com/emberjs/ember.js/blob/v2.10.0/packages/ember-debug/lib/deprecate.js#L97) ember deprecate requires 3 arguments.

Copy link
Member

@rwjblue rwjblue left a comment

Choose a reason for hiding this comment

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

We should probably add some tests to confirm deprecations that we add, just so this kind of thing doesn't go unnoticed...

@@ -1783,7 +1783,7 @@ Store = Service.extend({
@return {boolean}
*/
recordIsLoaded(modelName, id) {
deprecate(`Use of recordIsLoaded is deprecated, use hasRecordForId instead.`, {
deprecate(`Use of recordIsLoaded is deprecated, use hasRecordForId instead.`, true, {
Copy link
Member

Choose a reason for hiding this comment

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

This should be false not true. These deprecations (AFAICT) are never being triggered.

deprecate('foo', true, { id: 'asdf', until: 'asdf'}) doesn't actually deprecate anything, but deprecate('foo', false, { id: 'asdf', until: 'asdf'}) does.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

@rwjblue That's correct.

@bmac bmac merged commit 0c26d2d into emberjs:master Jan 23, 2017
@bmac
Copy link
Member

bmac commented Jan 23, 2017

Thanks @estshy.

bmac pushed a commit that referenced this pull request Feb 3, 2017
* Update deprecate arguments

According to docs (https://github.com/emberjs/ember.js/blob/v2.10.0/packages/ember-debug/lib/deprecate.js#L97) ember deprecate requires 3 arguments.

* Update store.js

(cherry picked from commit 0c26d2d)
bmac pushed a commit that referenced this pull request Feb 3, 2017
* Update deprecate arguments

According to docs (https://github.com/emberjs/ember.js/blob/v2.10.0/packages/ember-debug/lib/deprecate.js#L97) ember deprecate requires 3 arguments.

* Update store.js

(cherry picked from commit 0c26d2d)
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

3 participants