From 281416de3606a07db1b47fd15dc752e00cb1792a Mon Sep 17 00:00:00 2001 From: ITOH <72305210+itohatweb@users.noreply.github.com> Date: Fri, 23 Apr 2021 23:27:41 +0200 Subject: [PATCH] Update start_typing.ts --- src/helpers/channels/start_typing.ts | 6 ++---- 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/src/helpers/channels/start_typing.ts b/src/helpers/channels/start_typing.ts index c5cf0144b..013ad46e2 100644 --- a/src/helpers/channels/start_typing.ts +++ b/src/helpers/channels/start_typing.ts @@ -10,7 +10,7 @@ import { botHasChannelPermissions } from "../../util/permissions.ts"; * However, if a bot is responding to a command and expects the computation to take a few seconds, * this endpoint may be called to let the user know that the bot is processing their message. */ -export async function startTyping(channelId: string): Promise { +export async function startTyping(channelId: string) { const channel = await cacheHandlers.get("channels", channelId); // If the channel is cached, we can do extra checks/safety if (channel) { @@ -35,10 +35,8 @@ export async function startTyping(channelId: string): Promise { } } - const result = await rest.runMethod( + return await rest.runMethod( "post", endpoints.CHANNEL_TYPING(channelId), ); - - return result; }