public function checkPermissionIsEditable(BuildDataDefinitionEvent $event)
    {
        if (!$this->scopeDeterminator->currentScopeIsBackend()) {
            return;
        }

        $container = $event->getContainer();

        if ($container->getBasicDefinition()->isEditable()) {
            return;
        }

        $view          = $container->getDefinition(Contao2BackendViewDefinitionInterface::NAME);
        $modelCommands = $view->getModelCommands();

        $this->disableCommandByActionName($modelCommands, 'edit');
        $this->disableCommandByActionName($modelCommands, 'cut');
        $this->disableToggleCommand($modelCommands);
    }