fix query when admin/reseller has ips != unlimited, fixes #1345

Signed-off-by: Michael Kaufmann (d00p) <d00p@froxlor.org>