module Doorkeeper::ApplicationMixin::ClassMethods
def by_uid(uid)
-
(Doorkeeper::Application, nil)
- Application instance or nil
Parameters:
-
uid
(#to_s
) -- UID (any object that responds to `#to_s`)
def by_uid(uid) find_by(uid: uid.to_s) end
def by_uid_and_secret(uid, secret)
-
(Doorkeeper::Application, nil)
-
Parameters:
-
secret
(#to_s
) -- secret (any object that responds to `#to_s`) -
uid
(#to_s
) -- UID (any object that responds to `#to_s`)
def by_uid_and_secret(uid, secret) app = by_uid(uid) return unless app return app if secret.blank? && !app.confidential? return unless app.secret_matches?(secret) app end
def fallback_secret_strategy
Determine the fallback storing strategy
#
def fallback_secret_strategy ::Doorkeeper.config.application_secret_fallback_strategy end
def secret_strategy
Determines the secret storing transformer
#
def secret_strategy ::Doorkeeper.config.application_secret_strategy end