diff options
author | Ruben Davila <rdavila84@gmail.com> | 2017-05-19 13:35:08 -0500 |
---|---|---|
committer | Ruben Davila <rdavila84@gmail.com> | 2017-05-19 13:37:40 -0500 |
commit | 49ded5c1fa31abf004d85f369e8b464879bbd781 (patch) | |
tree | c4e2fb6201e2d40b81d38e6962d6e50344ccf3c0 /app/controllers/projects/issues_controller.rb | |
parent | bdf62a19d2cdbdfe554eb73500fd5fe4744161b1 (diff) | |
download | gitlab-ce-49ded5c1fa31abf004d85f369e8b464879bbd781.tar.gz |
Bugfix: don't redirect to JSON endpoints after sign in
Diffstat (limited to 'app/controllers/projects/issues_controller.rb')
-rw-r--r-- | app/controllers/projects/issues_controller.rb | 5 |
1 files changed, 4 insertions, 1 deletions
diff --git a/app/controllers/projects/issues_controller.rb b/app/controllers/projects/issues_controller.rb index 46438e68d54..cbef8fa94d4 100644 --- a/app/controllers/projects/issues_controller.rb +++ b/app/controllers/projects/issues_controller.rb @@ -277,7 +277,10 @@ class Projects::IssuesController < Projects::ApplicationController notice = "Please sign in to create the new issue." - store_location_for :user, request.fullpath + if request.get? && !request.xhr? + store_location_for :user, request.fullpath + end + redirect_to new_user_session_path, notice: notice end end |