diff --git a/extensions/mentions/js/src/forum/addComposerAutocomplete.js b/extensions/mentions/js/src/forum/addComposerAutocomplete.js
index <HASH>..<HASH> 100644
--- a/extensions/mentions/js/src/forum/addComposerAutocomplete.js
+++ b/extensions/mentions/js/src/forum/addComposerAutocomplete.js
@@ -206,7 +206,7 @@ export default function addComposerAutocomplete() {
 
   extend(TextEditor.prototype, 'toolbarItems', function(items) {
     items.add('mention', (
-      <TextEditorButton onclick={() => this.insertAtCursor('@')} icon="fas fa-at">
+      <TextEditorButton onclick={() => this.props.composer.editor.insertAtCursor('@')} icon="fas fa-at">
         {app.translator.trans('flarum-mentions.forum.composer.mention_tooltip')}
       </TextEditorButton>
     ));
Fix extension to work with Composer state changes

Refs flarum/core#<I>.