Browse Source

Fix form-action CSP directive for external login (#20962)

closed-social-glitch-2
Claire 2 years ago
committed by GitHub
parent
commit
48e136605a
No known key found for this signature in database GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 4 additions and 0 deletions
  1. +4
    -0
      app/controllers/auth/sessions_controller.rb

+ 4
- 0
app/controllers/auth/sessions_controller.rb View File

@ -14,6 +14,10 @@ class Auth::SessionsController < Devise::SessionsController
before_action :set_instance_presenter, only: [:new]
before_action :set_body_classes
content_security_policy only: :new do |p|
p.form_action(false)
end
def check_suspicious!
user = find_user
@login_is_suspicious = suspicious_sign_in?(user) unless user.nil?

Loading…
Cancel
Save