Fix query on attacker/victim

This commit is contained in:
Alfredo Cardigliano 2021-05-17 09:51:59 +02:00
parent ccb61a7444
commit 32585a34d0

View file

@ -105,9 +105,9 @@ function host_alert_store:add_role_filter(role)
if not self._role then
self._role = role
if role == 'attacker' then
self._where[#self._where + 1] = string.format("is_attacker = %s", true)
self._where[#self._where + 1] = "is_attacker = 1"
elseif role == 'victim' then
self._where[#self._where + 1] = string.format("is_victim = %s", true)
self._where[#self._where + 1] = "is_victim = 1"
end
return true
end