-
-
Save appgurueu/3dd56692814532d61caa02c941fa691b to your computer and use it in GitHub Desktop.
Fix revoke callbacks being run for `false` values passed to `set_privileges`
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
diff --git a/builtin/game/auth.lua b/builtin/game/auth.lua | |
index fa1860d5d..932021a0e 100644 | |
--- a/builtin/game/auth.lua | |
+++ b/builtin/game/auth.lua | |
@@ -101,7 +101,7 @@ core.builtin_auth_handler = { | |
-- Run revoke callbacks | |
for priv, _ in pairs(prev_privs) do | |
- if not privileges[priv] then | |
+ if privileges[priv] == nil then | |
core.run_priv_callbacks(name, priv, nil, "revoke") | |
end | |
end |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment