global csrf

This commit is contained in:
julien committed 2026-10-22 19:33:34 +02:00
1 parent 82f8b28353
commit 42a9218df4
2 files changed
+2 -3

No files matched your search

+2 -1
View File
@@ -9,7 +9,7 @@ class Netig < Roda
plugin :public
plugin :default_headers, "Content-Type" => "text/html; charset=utf-8"
plugin :sessions, secret: ENV.fetch("SESSION_SECRET")
plugin :route_csrf
plugin :route_csrf, csrf_failure: :empty_403
plugin :hash_branches
plugin :flash
@@ -17,6 +17,7 @@ class Netig < Roda
route do |r|
r.public
check_csrf!
r.hash_branches
r.root do