mirror of
https://github.com/discourse/discourse.git
synced 2025-03-22 07:35:38 +08:00
createWithMixins
is deprecated.
This commit is contained in:
parent
a50edb87ec
commit
1a3b63e07d
@ -8,7 +8,7 @@ define('ember', ['exports'], function(__exports__) {
|
|||||||
|
|
||||||
var _pluginCallbacks = [];
|
var _pluginCallbacks = [];
|
||||||
|
|
||||||
window.Discourse = Ember.Application.createWithMixins(Discourse.Ajax, {
|
window.Discourse = Ember.Application.extend(Discourse.Ajax, {
|
||||||
rootElement: '#main',
|
rootElement: '#main',
|
||||||
_docTitle: document.title,
|
_docTitle: document.title,
|
||||||
__TAGS_INCLUDED__: true,
|
__TAGS_INCLUDED__: true,
|
||||||
@ -168,7 +168,7 @@ window.Discourse = Ember.Application.createWithMixins(Discourse.Ajax, {
|
|||||||
return this.get("currentAssetVersion");
|
return this.get("currentAssetVersion");
|
||||||
}
|
}
|
||||||
})
|
})
|
||||||
});
|
}).create();
|
||||||
|
|
||||||
function RemovedObject(name) {
|
function RemovedObject(name) {
|
||||||
this._removedName = name;
|
this._removedName = name;
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
let _jumpScheduled = false;
|
let _jumpScheduled = false;
|
||||||
const rewrites = [];
|
const rewrites = [];
|
||||||
|
|
||||||
const DiscourseURL = Ember.Object.createWithMixins({
|
const DiscourseURL = Ember.Object.extend({
|
||||||
|
|
||||||
// Used for matching a topic
|
// Used for matching a topic
|
||||||
TOPIC_REGEXP: /\/t\/([^\/]+)\/(\d+)\/?(\d+)?/,
|
TOPIC_REGEXP: /\/t\/([^\/]+)\/(\d+)\/?(\d+)?/,
|
||||||
@ -327,7 +327,6 @@ const DiscourseURL = Ember.Object.createWithMixins({
|
|||||||
}
|
}
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
}).create();
|
||||||
});
|
|
||||||
|
|
||||||
export default DiscourseURL;
|
export default DiscourseURL;
|
||||||
|
@ -4,7 +4,7 @@ import SelectedPostsCount from 'discourse/mixins/selected-posts-count';
|
|||||||
import Topic from 'discourse/models/topic';
|
import Topic from 'discourse/models/topic';
|
||||||
|
|
||||||
var buildTestObj = function(params) {
|
var buildTestObj = function(params) {
|
||||||
return Ember.Object.createWithMixins(SelectedPostsCount, params || {});
|
return Ember.Object.extend(SelectedPostsCount).create(params || {});
|
||||||
};
|
};
|
||||||
|
|
||||||
test("without selectedPosts", function () {
|
test("without selectedPosts", function () {
|
||||||
|
Loading…
x
Reference in New Issue
Block a user