Skip to content

Commit

Permalink
[DOC beta] Refs emberjs#11835 - Update packages/ember-application so …
Browse files Browse the repository at this point in the history
…Ember.deprecate includes required options.
  • Loading branch information
EricSchank committed Jul 21, 2015
1 parent 0cdc134 commit 746d960
Showing 1 changed file with 15 additions and 3 deletions.
18 changes: 15 additions & 3 deletions packages/ember-application/lib/system/application.js
Original file line number Diff line number Diff line change
Expand Up @@ -552,7 +552,11 @@ var Application = Namespace.extend({
@method initialize
**/
initialize() {
Ember.deprecate('Calling initialize manually is not supported. Please see Ember.Application#advanceReadiness and Ember.Application#deferReadiness');
Ember.deprecate(
'Calling initialize manually is not supported. Please see Ember.Application#advanceReadiness and Ember.Application#deferReadiness',
false,
{ id: 'ember-application.initialize', until: '3.0.0' }
);
},

/**
Expand Down Expand Up @@ -1081,7 +1085,11 @@ Application.reopenClass({
@return {*} the resolved value for a given lookup
*/
function resolverFor(namespace) {
Ember.deprecate('Application.resolver is deprecated in favor of Application.Resolver', !namespace.get('resolver'));
Ember.deprecate(
'Application.resolver is deprecated in favor of Application.Resolver',
!namespace.get('resolver'),
{ id: 'ember-application.resolverFor', until: '3.0.0' }
);

var ResolverClass = namespace.get('resolver') || namespace.get('Resolver') || DefaultResolver;
var resolver = ResolverClass.create({
Expand All @@ -1104,7 +1112,11 @@ function resolverFor(namespace) {
if (resolver.normalize) {
return resolver.normalize(fullName);
} else {
Ember.deprecate('The Resolver should now provide a \'normalize\' function', false);
Ember.deprecate(
'The Resolver should now provide a \'normalize\' function',
false,
{ id: 'ember-application.resolve-normalize', until: '3.0.0' }
);
return fullName;
}
};
Expand Down

0 comments on commit 746d960

Please sign in to comment.