Skip to content
This repository has been archived by the owner on Sep 25, 2021. It is now read-only.

Commit

Permalink
Set X-XHR-Redirect header
Browse files Browse the repository at this point in the history
  • Loading branch information
mrhead committed Dec 14, 2017
1 parent 6a45fca commit 56cf714
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions lib/turbolinks/redirection.rb
Original file line number Diff line number Diff line change
Expand Up @@ -33,6 +33,7 @@ def visit_location_with_turbolinks(location, action)
self.status = 200
self.response_body = script.join("\n")
response.content_type = "text/javascript"
response.headers["X-Xhr-Redirect"] = location
end

def store_turbolinks_location_in_session(location)
Expand Down

0 comments on commit 56cf714

Please sign in to comment.