From 2125c51c9c057056cf10248c318befd27ee2f971 Mon Sep 17 00:00:00 2001 From: Elias Fleckenstein Date: Fri, 5 Mar 2021 10:20:19 +0100 Subject: [PATCH] Fix mcl_util.get_color --- mods/CORE/mcl_util/init.lua | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/mods/CORE/mcl_util/init.lua b/mods/CORE/mcl_util/init.lua index ec2aa3017..a43c3d5d0 100644 --- a/mods/CORE/mcl_util/init.lua +++ b/mods/CORE/mcl_util/init.lua @@ -409,9 +409,8 @@ end function mcl_util.get_color(colorstr) local mc_color = mcl_colors[colorstr:upper()] if mc_color then - return mc_color - end - if #colorstr ~= 7 or colorstr:sub(1, 1) ~= "#"then + colorstr = mc_color + elseif #colorstr ~= 7 or colorstr:sub(1, 1) ~= "#"then return end local hex = tonumber(colorstr:sub(2, 7), 16)