Skip to content
This repository has been archived by the owner on Jun 19, 2020. It is now read-only.

Commit

Permalink
Fix permission ordering in world plugin
Browse files Browse the repository at this point in the history
  • Loading branch information
vexyl committed Aug 7, 2018
1 parent 8a4efcc commit 816c154
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 4 deletions.
2 changes: 1 addition & 1 deletion plugins/core/permissions.lua
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ end

PermissionsPlugin.RequirePermission = function(permission)
table.insert(PermissionsPlugin.permissionList, permission)
print("PermissionsPlugin new permission: " .. permission)
Server.LogDebug("PermissionsPlugin new permission: " .. permission)
end

PermissionsPlugin.PermissionExists = function(permission)
Expand Down
2 changes: 1 addition & 1 deletion plugins/essentials/ban.lua
Original file line number Diff line number Diff line change
Expand Up @@ -130,7 +130,7 @@ EssentialsPlugin.Ban_OnConnect = function(client, args)
end

Server.KickClient(client, message)
print("Ban plugin prevented player " .. name .. " from joining.")
Server.LogDebug("Ban plugin prevented player " .. name .. " from joining.")
Flags.NoDefaultCall = 1
end
end
Expand Down
5 changes: 5 additions & 0 deletions plugins/essentials/groups.lua
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,11 @@ EssentialsPlugin.Groups_GroupsCommand_Reload = function(client, args)
EssentialsPlugin.Groups_LoadGroups()

Server.SendMessage(client, "&eReloaded groups")

-- hack to reload current players
for _,v in pairs(Server.GetClients()) do
EssentialsPlugin.Groups_OnAuth(v, nil)
end
end

EssentialsPlugin.Groups_OnAuth = function(client, args)
Expand Down
4 changes: 2 additions & 2 deletions plugins/essentials/world.lua
Original file line number Diff line number Diff line change
Expand Up @@ -23,8 +23,8 @@ Init = function()
end,

HasWorldPermission = function(client)
return PermissionsPlugin.CheckPermissionNotify(client, client:GetWorld():GetName() .. ".admin")
or PermissionsPlugin.CheckPermissionIfExists(client.name, "essentials.world")
return PermissionsPlugin.CheckPermissionIfExists(client.name, "essentials.world")
or PermissionsPlugin.CheckPermissionNotify(client, client:GetWorld():GetName() .. ".admin")
end,

Event_OnBlock = function(client, block)
Expand Down

0 comments on commit 816c154

Please sign in to comment.