From e450560093619cd896a6a92031e9e6c325aefab4 Mon Sep 17 00:00:00 2001 From: Alexander Ebert Date: Mon, 11 Mar 2024 16:36:34 +0100 Subject: [PATCH] Migrate the mentions to the new API endpoint --- ts/WoltLabSuite/Core/Component/Ckeditor/Mention.ts | 2 +- .../files/js/WoltLabSuite/Core/Component/Ckeditor/Mention.js | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/ts/WoltLabSuite/Core/Component/Ckeditor/Mention.ts b/ts/WoltLabSuite/Core/Component/Ckeditor/Mention.ts index 57bf0cdb51..2cc92f6d79 100644 --- a/ts/WoltLabSuite/Core/Component/Ckeditor/Mention.ts +++ b/ts/WoltLabSuite/Core/Component/Ckeditor/Mention.ts @@ -40,7 +40,7 @@ async function getPossibleMentions(query: string): Promise { } // TODO: Provide the URL as a parameter. - const url = new URL(window.WSC_API_URL + "index.php?editor-get-mention-suggestions/"); + const url = new URL(window.WSC_API_URL + "index.php?api/rpc/core/messages/mentionsuggestions"); url.searchParams.set("query", query); const result = (await prepareRequest(url.toString()) diff --git a/wcfsetup/install/files/js/WoltLabSuite/Core/Component/Ckeditor/Mention.js b/wcfsetup/install/files/js/WoltLabSuite/Core/Component/Ckeditor/Mention.js index 8940363547..5efaec501e 100644 --- a/wcfsetup/install/files/js/WoltLabSuite/Core/Component/Ckeditor/Mention.js +++ b/wcfsetup/install/files/js/WoltLabSuite/Core/Component/Ckeditor/Mention.js @@ -17,7 +17,7 @@ define(["require", "exports", "../../Ajax/Backend", "../../Dom/Util", "./Event"] return []; } // TODO: Provide the URL as a parameter. - const url = new URL(window.WSC_API_URL + "index.php?editor-get-mention-suggestions/"); + const url = new URL(window.WSC_API_URL + "index.php?api/rpc/core/messages/mentionsuggestions"); url.searchParams.set("query", query); const result = (await (0, Backend_1.prepareRequest)(url.toString()) .get() -- 2.20.1