src/Contao/View/Contao2BackendView/Subscriber/CheckPermission.php
private function disableToggleCommand(CommandCollectionInterface $commands)
    {
        foreach ($commands->getCommands() as $command) {
            if (!($command instanceof ToggleCommandInterface)) {
                continue;
            }

            $this->disableCommandByActionName($commands, $command->getName());
        }
    }
private function disableToggleCommand(CommandCollectionInterface $commands)
    {
        foreach ($commands->getCommands() as $command) {
            if (!($command instanceof ToggleCommandInterface)) {
                continue;
            }

            $this->disableCommandByActionName($commands, $command->getName());
        }
    }
private function disableToggleCommand ( CommandCollectionInterface $ commands ) { foreach ( $ commands -> getCommands ( ) as $ command ) { if ( ! ( $ command instanceof ToggleCommandInterface ) ) { continue ; } $ this -> disableCommandByActionName ( $ commands , $ command -> getName ( ) ) ; } }
Disable the toggle command.

@param CommandCollectionInterface $commands The commands collection.

@return void
Disable the toggle command .