0
0
Fork 0

Add force_login option to OAuth authorize page (#8655)

* Add force_login option to OAuth authorize page

For when a user needs to sign into an app from multiple accounts
on the same server

* When logging out from modal header, redirect back after re-login
This commit is contained in:
Eugen Rochko 2018-09-09 04:10:44 +02:00 committed by GitHub
parent 2492c12281
commit 2288d50a7b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
7 changed files with 62 additions and 9 deletions

View file

@ -53,10 +53,6 @@ class Api::BaseController < ApplicationController
[params[:limit].to_i.abs, default_limit * 2].min
end
def truthy_param?(key)
ActiveModel::Type::Boolean.new.cast(params[key])
end
def current_resource_owner
@current_user ||= User.find(doorkeeper_token.resource_owner_id) if doorkeeper_token
end