kanersps / es_admin

GNU Affero General Public License v3.0
26 stars 32 forks source link

Everyone can open es_admin2 why??? #20

Open benzon opened 4 years ago

benzon commented 4 years ago

So with the latest update you changed something that i dont understand one bit off.

https://github.com/kanersps/es_admin/blob/bd4fcd3284c7a5d90f0c6cf8db9a506f6537e5f8/client.lua#L11

Why did you do this like if true that will always be true, dont get the point of that, gives everyone access to the admin panel, is that something they should have doubt it?

if (IsControlJustPressed(1, 212) and IsControlJustPressed(1, 213)) then
            if true then
                SetNuiFocus(true, true)
                SendNUIMessage({type = 'open', players = getPlayers()})
            end
        end
Leon485 commented 4 years ago

Do you know how to change it so only admins can open it?

RoccoRP commented 2 years ago

i have the same problem , any solutions ??

0vm commented 1 year ago

why dont you just put an admin check after the line