From 86afe76c91d8851d18b8a4b678efec94083824f8 Mon Sep 17 00:00:00 2001 From: Chris Johnston Date: Mon, 20 Aug 2018 21:35:32 -0700 Subject: [PATCH] Revert changes to DiscordRestApiClient --- src/Discord.Net.Rest/DiscordRestApiClient.cs | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/src/Discord.Net.Rest/DiscordRestApiClient.cs b/src/Discord.Net.Rest/DiscordRestApiClient.cs index 2f808cd1f..2236dbbf8 100644 --- a/src/Discord.Net.Rest/DiscordRestApiClient.cs +++ b/src/Discord.Net.Rest/DiscordRestApiClient.cs @@ -72,16 +72,6 @@ namespace Discord.API case default(TokenType): return token; case TokenType.Bot: - // Validate that the supplied bot token is at least 50 characters long. - // Using other tokens and the ones in the discord docs as an example, - // bot tokens typically appear to be 59 characters long, but it is unknown - // if this is a constant. - // This validation helps catch users who input the wrong type of token (bearer, client secret) - // instead of a Bot token. - if (token.Length <= 50) - { - throw new ArgumentException("Invalid Bot token length.", nameof(token)); - } return $"Bot {token}"; case TokenType.Bearer: return $"Bearer {token}";