fix: constant urls endpoints need to be functions

This commit is contained in:
Skillz4Killz
2022-03-25 19:23:44 +00:00
committed by GitHub
parent 18bf53ac6b
commit fbbac43053
12 changed files with 27 additions and 22 deletions
+1 -1
View File
@@ -4,7 +4,7 @@ import { Collection } from "../../util/collection.ts";
/** Returns an array of voice regions that can be used when creating servers. */
export async function getAvailableVoiceRegions(bot: Bot) {
const result = await bot.rest.runMethod<DiscordVoiceRegion[]>(bot.rest, "get", bot.constants.endpoints.VOICE_REGIONS);
const result = await bot.rest.runMethod<DiscordVoiceRegion[]>(bot.rest, "get", bot.constants.endpoints.VOICE_REGIONS());
return new Collection(
result.map((region) => {