|
@@ -11,12 +11,13 @@ function modpol.orgs:call_module(module_slug, initiator, config, result, parent_
|
|
|
|
|
|
-- first, if no slug, just run result
|
|
|
-- may not be necessary if we use false as default approval_module
|
|
|
- if not module_slug
|
|
|
- and result() then
|
|
|
- result()
|
|
|
+ if not module_slug then
|
|
|
+ if result() then
|
|
|
+ result()
|
|
|
+ end
|
|
|
return
|
|
|
+ -- if module doesn't exist, abort
|
|
|
elseif not modpol.modules[module_slug] then
|
|
|
- -- if module doesn't exist, abort
|
|
|
modpol.ocutil.log('Error in ' .. self.name .. ':call_module -> module "' .. tostring(module_slug) .. '" not found')
|
|
|
return
|
|
|
end
|