using utility function to check user, typo

This commit is contained in:
Alfredo Cardigliano 2018-07-31 17:43:39 +02:00
parent 3acc4e973d
commit 4e1ea506b9
2 changed files with 2 additions and 3 deletions

View file

@ -25,8 +25,7 @@ local function send_error(error_type)
print(json.encode({error = msg}))
end
user_group = ntop.getUserGroup()
if user_group ~= "administrator" then
if not isAdministrator() then
send_error("not_granted")
else