self.packages[scheme] = sc()
return true
else
- return false, so:error(ERR.SME_READ(so,file))
- end
+ return false, so:error(ERR.SME_READ(so,bc))
+ end
end
end
local oo = so:option(r[3])
local eo = oo:enum(v.value)
- if t.type ~= "enum" then
+ if t.type ~= "enum" and t.type ~= "reference" then
return false, scheme:error(ERR.SME_EBADTYPE(eo))
end
--- Get the value of this option.
-- @return The associated configuration value
function option.value(self)
- local v = self:config()
+ local v = self:config() or self:scheme('default')
if v and self:scheme('multival') then
v = luci.util.split( v, "%s+", nil, true )
end