be42c05054
Enables frozen string for the following: * app/controllers/dashboard/**/*.rb * app/controllers/explore/**/*.rb * app/controllers/google_api/**/*.rb * app/controllers/groups/**/*.rb * app/controllers/import/**/*.rb * app/controllers/instance_statistics/**/*.rb * app/controllers/ldap/**/*.rb * app/controllers/oauth/**/*.rb * app/controllers/profiles/**/*.rb Partially addresses #47424.
21 lines
573 B
Ruby
21 lines
573 B
Ruby
# frozen_string_literal: true
|
|
|
|
class Oauth::AuthorizationsController < Doorkeeper::AuthorizationsController
|
|
layout 'profile'
|
|
|
|
# Overriden from Doorkeeper::AuthorizationsController to
|
|
# include the call to session.delete
|
|
def new
|
|
if pre_auth.authorizable?
|
|
if skip_authorization? || matching_token?
|
|
auth = authorization.authorize
|
|
session.delete(:user_return_to)
|
|
redirect_to auth.redirect_uri
|
|
else
|
|
render "doorkeeper/authorizations/new"
|
|
end
|
|
else
|
|
render "doorkeeper/authorizations/error"
|
|
end
|
|
end
|
|
end
|