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

[BUGFIX] Reverts the naming of setClassicDecorator externally #17833

Merged
merged 2 commits into from
Apr 2, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 14 additions & 0 deletions packages/ember/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -275,6 +275,20 @@ Ember._tracked = metal.tracked;
computed.alias = metal.alias;
Ember.cacheFor = metal.getCachedValueFor;
Ember.ComputedProperty = metal.ComputedProperty;
Object.defineProperty(Ember, '_setComputedDecorator', {
get() {
deprecate(
'Please migrate from Ember._setComputedDecorator to Ember._setClassicDecorator',
false,
{
id: 'ember._setComputedDecorator',
until: '3.13.0',
}
);

return metal.setClassicDecorator;
},
});
Ember._setClassicDecorator = metal.setClassicDecorator;
Ember.meta = meta;
Ember.get = metal.get;
Expand Down
6 changes: 6 additions & 0 deletions packages/ember/tests/reexports_test.js
Original file line number Diff line number Diff line change
Expand Up @@ -49,6 +49,12 @@ moduleFor(
);
}
}

'@test Ember._setComputedDecorator is deprecated'() {
expectDeprecation(() => {
Ember._setComputedDecorator;
}, 'Please migrate from Ember._setComputedDecorator to Ember._setClassicDecorator');
}
}
);

Expand Down