From 85de760ad006575bfb61472be0aa346406ac7d2c Mon Sep 17 00:00:00 2001 From: brad90four <42116429+brad90four@users.noreply.github.com> Date: Wed, 15 Sep 2021 16:16:52 -0400 Subject: Fix Flake8 spacing errors --- bot/exts/utilities/color.py | 16 ++++++++-------- 1 file changed, 8 insertions(+), 8 deletions(-) (limited to 'bot') diff --git a/bot/exts/utilities/color.py b/bot/exts/utilities/color.py index dd470197..eb9d5f4d 100644 --- a/bot/exts/utilities/color.py +++ b/bot/exts/utilities/color.py @@ -155,19 +155,19 @@ class Color(commands.Cog): def _rgb_to_hsv(rgb_color: tuple[int, int, int]) -> tuple[int, int, int]: """To convert from `RGB` to `HSV` color space.""" r, g, b = rgb_color - h, v, s = colorsys.rgb_to_hsv(r/float(255), g/float(255), b/float(255)) - h = round(h*360) - s = round(s*100) - v = round(v*100) + h, v, s = colorsys.rgb_to_hsv(r / float(255), g / float(255), b / float(255)) + h = round(h * 360) + s = round(s * 100) + v = round(v * 100) return h, s, v def _rgb_to_hsl(rgb_color: tuple[int, int, int]) -> tuple[int, int, int]: """To convert from `RGB` to `HSL` color space.""" r, g, b = rgb_color - h, l, s = colorsys.rgb_to_hls(r/float(255), g/float(255), b/float(255)) - h = round(h*360) - s = round(s*100) - l = round(l*100) # noqa: E741 It's little `L`, Reason: To maintain consistency. + h, l, s = colorsys.rgb_to_hls(r / float(255), g / float(255), b / float(255)) + h = round(h * 360) + s = round(s * 100) + l = round(l * 100) # noqa: E741 It's little `L`, Reason: To maintain consistency. return h, s, l hex_color = _rgb_to_hex(rgb_color) -- cgit v1.2.3