mirror of
https://github.com/discourse/discourse.git
synced 2025-09-08 12:06:51 +08:00
Migrate onToolbarCreate
to the DiscourseAPI
This commit is contained in:
parent
7b8e313dac
commit
f6aa1ac37a
4 changed files with 30 additions and 16 deletions
|
@ -176,8 +176,13 @@ class Toolbar {
|
|||
}
|
||||
}
|
||||
|
||||
export function onToolbarCreate(func) {
|
||||
export function addToolbarCallback(func) {
|
||||
_createCallbacks.push(func);
|
||||
}
|
||||
|
||||
export function onToolbarCreate(func) {
|
||||
console.warn('`onToolbarCreate` is deprecated, use the plugin api instead.');
|
||||
addToolbarCallback(func);
|
||||
};
|
||||
|
||||
export default Ember.Component.extend({
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue