From 616e644de7e6954572b09e01d38f907b82bcf778 Mon Sep 17 00:00:00 2001 From: Alexander Ebert Date: Tue, 31 May 2022 11:13:26 +0200 Subject: [PATCH] Simplified the code a bit MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Co-authored-by: Tim Düsterhus --- ts/WoltLabSuite/Core/ColorUtil.ts | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/ts/WoltLabSuite/Core/ColorUtil.ts b/ts/WoltLabSuite/Core/ColorUtil.ts index d2c7618e74..4398ee183b 100644 --- a/ts/WoltLabSuite/Core/ColorUtil.ts +++ b/ts/WoltLabSuite/Core/ColorUtil.ts @@ -119,8 +119,8 @@ export function rgbToHsl(r: number, g: number, b: number): HSL { g /= 255; b /= 255; - const max = Math.max(Math.max(r, g), b); - const min = Math.min(Math.min(r, g), b); + const max = Math.max(r, g, b); + const min = Math.min(r, g, b); const diff = max - min; h = 0; -- 2.20.1