From a0634b3eea2de6910d9112608fc12c31e7117554 Mon Sep 17 00:00:00 2001 From: Hornwitser Date: Thu, 9 Aug 2018 14:17:03 +0200 Subject: [PATCH] =?UTF-8?q?[lint]=C2=A0Simplyfy=20util.valid=5Ficon=5Fsize?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Remove redundant paranthesis and checks from util.valid_icon_size. --- discord/utils.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/discord/utils.py b/discord/utils.py index bb1e4d53b..8c4c57348 100644 --- a/discord/utils.py +++ b/discord/utils.py @@ -291,7 +291,7 @@ async def sane_wait_for(futures, *, timeout, loop): def valid_icon_size(size): """Icons must be power of 2 within [16, 2048].""" - return ((size != 0) and not (size & (size - 1))) and size in range(16, 2049) + return not size & (size - 1) and size in range(16, 2049) class SnowflakeList(array.array): """Internal data storage class to efficiently store a list of snowflakes.