Cake\Controller\Component\AuthComponent::allow PHP Method

allow() public method

You can use allow with either an array or a simple string. $this->Auth->allow('view'); $this->Auth->allow(['edit', 'add']); or to allow all actions $this->Auth->allow();
public allow ( string | array | null $actions = null ) : void
$actions string | array | null Controller action name or array of actions
return void
    public function allow($actions = null)
    {
        if ($actions === null) {
            $controller = $this->_registry->getController();
            $this->allowedActions = get_class_methods($controller);
            return;
        }
        $this->allowedActions = array_merge($this->allowedActions, (array) $actions);
    }