public function execute(array $options, $username)
    {
        $data = $options["data"];
        $moveOptions = array(
            'page' => $data['page'],
            'language' => $data['language'],
            'country' => $data['country'],
            'sourceSlot' => $data['sourceSlot'],
            'oldName' => $data['oldName'],
            'newName' => $data['newName'],
            'position' => $data['position'],
        );

        if (array_key_exists('name', $data)) {
            $moveOptions['blockname'] = $data['name'];
        }

        if (array_key_exists('targetSlot', $data) && null !== $data['targetSlot']) {
            $moveOptions['targetSlot'] = $data['targetSlot'];
        }

        $blockManager = $this->app["red_kite_cms.blocks_manager_factory"]->create('move');

        return $blockManager->move($this->app["red_kite_cms.configuration_handler"]->siteDir(), $moveOptions, $username);
    }
public function execute(array $options, $username)
    {
        $data = $options["data"];
        $moveOptions = array(
            'page' => $data['page'],
            'language' => $data['language'],
            'country' => $data['country'],
            'sourceSlot' => $data['sourceSlot'],
            'oldName' => $data['oldName'],
            'newName' => $data['newName'],
            'position' => $data['position'],
        );

        if (array_key_exists('name', $data)) {
            $moveOptions['blockname'] = $data['name'];
        }

        if (array_key_exists('targetSlot', $data) && null !== $data['targetSlot']) {
            $moveOptions['targetSlot'] = $data['targetSlot'];
        }

        $blockManager = $this->app["red_kite_cms.blocks_manager_factory"]->create('move');

        return $blockManager->move($this->app["red_kite_cms.configuration_handler"]->siteDir(), $moveOptions, $username);
    }
{@inheritdoc}