diff options
-rw-r--r-- | libs/cbi/luasrc/cbi.lua | 7 |
1 files changed, 6 insertions, 1 deletions
diff --git a/libs/cbi/luasrc/cbi.lua b/libs/cbi/luasrc/cbi.lua index b6ccc5480..88203660c 100644 --- a/libs/cbi/luasrc/cbi.lua +++ b/libs/cbi/luasrc/cbi.lua @@ -577,7 +577,12 @@ function SimpleForm.parse(self, readinput, ...) or valid and FORM_VALID or FORM_INVALID - self.dorender = not self.handle or self:handle(state, self.data) ~= false + self.dorender = not self.handle + if self.handle then + local nrender, nstate = self:handle(state, self.data) + self.dorender = self.dorender or (nrender ~= false) + state = nstate or state + end return state end |