Commit 8f4e609a authored by Kaarle Ritvanen's avatar Kaarle Ritvanen

detect invalid import references

parent c0284e07
......@@ -157,7 +157,11 @@ function PolicySet:load()
if not data.after then data.after = data.import end
for i, name in util.listpairs(data.import) do
require(self.policies[name])
local pol = self.policies[name]
if not pol then
raise('Invalid policy reference from '..policy.name..': '..name)
end
require(pol)
end
end
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment