-
-
Notifications
You must be signed in to change notification settings - Fork 1.3k
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
Conversation
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.
There was a problem hiding this 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, { |
There was a problem hiding this comment.
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.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@rwjblue That's correct.
Thanks @estshy. |
* 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)
* 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)
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.