mirror of
https://github.com/elyby/oauth2-server.git
synced 2024-11-15 09:47:46 +05:30
Updated PSR compliance. Added Illuminate\Support\Facades\DB namespace
This commit is contained in:
parent
4d36ebd3e7
commit
32a7ed38a9
@ -2,6 +2,7 @@
|
||||
|
||||
namespace League\OAuth2\Server\Storage\Fluent;
|
||||
|
||||
use \Illuminate\Support\Facades\DB as DB;
|
||||
use \League\OAuth2\Server\Storage\ClientInterface;
|
||||
|
||||
class Client implements ClientInterface {
|
||||
@ -14,16 +15,12 @@ class Client implements ClientInterface {
|
||||
->where('oauth_clients.id', $clientId)
|
||||
->where('oauth_client_endpoints.redirect_uri', $redirectUri)
|
||||
->first();
|
||||
}
|
||||
|
||||
elseif ( ! is_null($clientSecret) && is_null($redirectUri)) {
|
||||
} elseif ( ! is_null($clientSecret) && is_null($redirectUri)) {
|
||||
$result = DB::table('oauth_clients')
|
||||
->where('id', $clientId)
|
||||
->where('secret', $clientSecret)
|
||||
->first();
|
||||
}
|
||||
|
||||
elseif ( ! is_null($clientSecret) && ! is_null($redirectUri)) {
|
||||
} elseif ( ! is_null($clientSecret) && ! is_null($redirectUri)) {
|
||||
$result = DB::table('oauth_clients')
|
||||
->join('oauth_client_endpoints', 'oauth_clients.id', '=', 'oauth_client_endpoints.client_id')
|
||||
->where('oauth_clients.id', $clientId)
|
||||
|
Loading…
Reference in New Issue
Block a user