public static function can($action, $object=null, $message=null)
    {
        if (!static::getAuthorizer()->can($action, $object)) {
            throw new Exception($message ?: self::DEFAULT_MSG , 112);
        }
        return true;
    }
public static function can($action, $object=null, $message=null)
    {
        if (!static::getAuthorizer()->can($action, $object)) {
            throw new Exception($message ?: self::DEFAULT_MSG , 112);
        }
        return true;
    }
public static function can ( $ action , $ object = null , $ message = null ) { if ( ! static :: getAuthorizer ( ) -> can ( $ action , $ object ) ) { throw new Exception ( $ message ? : self :: DEFAULT_MSG , 112 ) ; } return true ; }
Verify if the current user is allowed to make an action

@param $action
@param null $object
@param null $message
@return bool
@throws Exception
Verify if the current user is allowed to make an action