mirror of
https://github.com/NodeBB/NodeBB.git
synced 2025-10-26 16:46:12 +01:00
refactor: don't use composer directly, use the post hook
This commit is contained in:
@@ -1,10 +1,10 @@
|
||||
'use strict';
|
||||
|
||||
define('quickreply', [
|
||||
'components', 'composer', 'composer/autocomplete', 'api',
|
||||
'components', 'composer/autocomplete', 'api',
|
||||
'alerts', 'uploadHelpers', 'mousetrap', 'storage', 'hooks',
|
||||
], function (
|
||||
components, composer, autocomplete, api,
|
||||
components, autocomplete, api,
|
||||
alerts, uploadHelpers, mousetrap, storage, hooks
|
||||
) {
|
||||
const QuickReply = {};
|
||||
@@ -113,7 +113,7 @@ define('quickreply', [
|
||||
e.preventDefault();
|
||||
storage.removeItem(qrDraftId);
|
||||
const textEl = components.get('topic/quickreply/text');
|
||||
composer.newReply({
|
||||
hooks.fire('action:composer.post.new', {
|
||||
tid: ajaxify.data.tid,
|
||||
title: ajaxify.data.titleRaw,
|
||||
body: textEl.val(),
|
||||
|
||||
Reference in New Issue
Block a user