src/Authentication.php
public function authorize(AuthorizerInterface $authorizer, AdapterInterface $adapter, array $credentials, $payload = null)
    {
        try {
            $user = $authorizer->verifyCredentials($credentials);
            $authenticated_with = $adapter->authenticate($user, $credentials);

            $this->triggerEvent('user_authorized', $user, $authenticated_with);

            return new AuthorizationTransport($adapter, $user, $authenticated_with, $payload);
        } catch (Exception $e) {
            $this->triggerEvent('user_authorization_failed', $credentials, $e);

            throw $e;
        }
    }
public function authorize(AuthorizerInterface $authorizer, AdapterInterface $adapter, array $credentials, $payload = null)
    {
        try {
            $user = $authorizer->verifyCredentials($credentials);
            $authenticated_with = $adapter->authenticate($user, $credentials);

            $this->triggerEvent('user_authorized', $user, $authenticated_with);

            return new AuthorizationTransport($adapter, $user, $authenticated_with, $payload);
        } catch (Exception $e) {
            $this->triggerEvent('user_authorization_failed', $credentials, $e);

            throw $e;
        }
    }
{@inheritdoc}