From 3171346d4b02f49ced518c081a62e63dbc871161 Mon Sep 17 00:00:00 2001 From: Rainnny7 Date: Mon, 15 Apr 2024 09:40:19 -0400 Subject: [PATCH] Fix #isMojangBlocked not working --- JS-SDK/src/lib/restfulmc.ts | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/JS-SDK/src/lib/restfulmc.ts b/JS-SDK/src/lib/restfulmc.ts index 5cd430d..c0c8a62 100644 --- a/JS-SDK/src/lib/restfulmc.ts +++ b/JS-SDK/src/lib/restfulmc.ts @@ -61,7 +61,9 @@ export const getMinecraftServer = ( * @returns the promised blocked status */ export const isMojangBlocked = (hostname: string): Promise => - new WebRequest(`/server/blocked/${hostname}`).execute(); + new WebRequest(`/server/blocked/${hostname}`).execute<{ + blocked: boolean; + }>().then((res) => res.blocked); /** * Get the icon of the Java Minecraft