summaryrefslogtreecommitdiffhomepage
path: root/modules/admin-mini
diff options
context:
space:
mode:
Diffstat (limited to 'modules/admin-mini')
-rw-r--r--modules/admin-mini/luasrc/controller/mini/index.lua6
1 files changed, 6 insertions, 0 deletions
diff --git a/modules/admin-mini/luasrc/controller/mini/index.lua b/modules/admin-mini/luasrc/controller/mini/index.lua
index b538310aa..dad6ccfab 100644
--- a/modules/admin-mini/luasrc/controller/mini/index.lua
+++ b/modules/admin-mini/luasrc/controller/mini/index.lua
@@ -40,6 +40,12 @@ function index()
end
function action_logout()
+ local dsp = require "luci.dispatcher"
+ local sauth = require "luci.sauth"
+ if dsp.context.authsession then
+ sauth.kill(dsp.context.authsession)
+ end
+
luci.http.header("Set-Cookie", "sysauth=; path=/")
luci.http.redirect(luci.dispatcher.build_url())
end \ No newline at end of file