TinyAuth\Auth\TinyAuthorize::authorize PHP Méthode

authorize() public méthode

Allows single or multi role based authorization Examples: - User HABTM Roles (Role array in User array) - User belongsTo Roles (role_id in User array)
public authorize ( array $user, Cake\Network\Request $request ) : boolean
$user array The user to authorize
$request Cake\Network\Request The request needing authorization.
Résultat boolean Success
    public function authorize($user, Request $request)
    {
        return $this->_check($user, $request->params);
    }