function Luci.handle_head(self, ...)
local response, sourceout = self:handle_get(...)
- self.running = self.running - 1
return response
end
local res, id, data1, data2 = true, 0, nil, nil
local headers = {}
local status = 200
+ local active = true
local x = coroutine.create(luci.dispatcher.httpdispatch)
while not id or id < 3 do
status = 500
headers["Content-Type"] = "text/plain"
local err = {id}
- self.running = self.running - 1
return Response( status, headers ), function() return table.remove(err) end
end
local res, id, data = coroutine.resume(x)
if not res then
return nil, id
- elseif not id then
+ elseif not id or not active then
return true
elseif id == 5 then
+ active = false
return true
elseif id == 4 then
return data