mirror of
https://github.com/discourse/discourse.git
synced 2024-11-22 15:25:35 +08:00
REFACTOR: Remove Discourse.SiteSettimgs
from @setting decorator
This commit is contained in:
parent
4ecb4439b9
commit
939fae3500
|
@ -162,6 +162,6 @@ export function endWith() {
|
|||
**/
|
||||
export function setting(name) {
|
||||
return computed(function() {
|
||||
return Discourse.SiteSettings[name];
|
||||
return this.siteSettings[name];
|
||||
});
|
||||
}
|
||||
|
|
|
@ -25,7 +25,8 @@ discourseModule("lib:computed", {
|
|||
});
|
||||
|
||||
QUnit.test("setting", function(assert) {
|
||||
var t = EmberObject.extend({
|
||||
let t = EmberObject.extend({
|
||||
siteSettings: this.siteSettings,
|
||||
vehicle: setting("vehicle"),
|
||||
missingProp: setting("madeUpThing")
|
||||
}).create();
|
||||
|
|
Loading…
Reference in New Issue
Block a user