From 552e87bd4bba2b30e1ae49f6ce997f46f5082465 Mon Sep 17 00:00:00 2001 From: Alex Young Date: Mon, 20 Apr 2015 16:30:54 +0100 Subject: Add Rack::Protection exception for ajax json requests --- lib/mauve/web_interface.rb | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/mauve/web_interface.rb b/lib/mauve/web_interface.rb index 896b9cb..5fa1fb8 100644 --- a/lib/mauve/web_interface.rb +++ b/lib/mauve/web_interface.rb @@ -66,6 +66,9 @@ module Mauve set :raise_errors, false # ...will not let exceptions out to main program set :show_exceptions, false # ...will not show exceptions + # We need this to avoid 403's on AJAX requests + set :protection, :except => :json_csrf + # # Default template. # -- cgit v1.2.1