Use the new constant `WSC_RPC_API_URL`.
authorCyperghost <olaf_schmitz_1@t-online.de>
Fri, 6 Sep 2024 09:57:00 +0000 (11:57 +0200)
committerCyperghost <olaf_schmitz_1@t-online.de>
Fri, 6 Sep 2024 09:57:00 +0000 (11:57 +0200)
See https://github.com/WoltLab/WCF/pull/5989

docs/javascript/components_rpc_api.md

index be18b971bc10ca9452768fbff353e9d16c38a5e9..de7a0a6a303130b8d2caff5954e04941694eac1a 100644 (file)
@@ -29,7 +29,7 @@ export async function renderComment(
   objectTypeId: number | undefined = undefined
 ): Promise<ApiResult<Response>> {
   const url = new URL(
-    `${window.WSC_API_URL}index.php?api/rpc/core/comments/${commentId}/render`
+    `${window.WSC_RPC_API_URL}core/comments/${commentId}/render`
   );
   url.searchParams.set("messageOnly", messageOnly.toString());
   if (responseId !== undefined) {