simplified request params check
This commit is contained in:
parent
56ab80d08e
commit
0f41e15845
@ -108,12 +108,8 @@ function modpol.orgs:make_request(request)
|
||||
return false
|
||||
end
|
||||
|
||||
-- num_params should equal zero at the end if request.params matches the num of params for that type
|
||||
for k, v in ipairs(request.params) do
|
||||
num_params = num_params - 1
|
||||
end
|
||||
|
||||
if num_params ~= 0 then
|
||||
-- request.params should match the num of params for that type
|
||||
if #request.params ~= num_params then
|
||||
modpol.ocutil.log('Error in ' .. self.name .. ':make_request -> request has invalid number of parameters')
|
||||
return false
|
||||
end
|
||||
|
Loading…
x
Reference in New Issue
Block a user