Fix toolbar buttons not showing on role assign

This commit is contained in:
Cooldude2606
2025-03-07 14:38:31 +00:00
parent 7504043b05
commit 64e31adbc9

View File

@@ -494,7 +494,7 @@ function Toolbar._ensure_consistency(player)
if type(allowed) == "function" then if type(allowed) == "function" then
allowed = allowed(player, element) allowed = allowed(player, element)
end end
element.visible = allowed and element.visible or false element.visible = allowed or false
list[button.name].visible = element.visible list[button.name].visible = element.visible
-- Update the toggle state and hide the linked left element if the button is not allowed -- Update the toggle state and hide the linked left element if the button is not allowed