lib/Core/Service/BlockService.php
private function internalMoveBlock(PersistenceBlock $block, PersistenceBlock $targetBlock, string $placeholder, int $position): PersistenceBlock
    {
        return $this->transaction(
            function () use ($block, $targetBlock, $placeholder, $position): PersistenceBlock {
                if ($block->parentId === $targetBlock->id && $block->placeholder === $placeholder) {
                    return $this->blockHandler->moveBlockToPosition($block, $position);
                }

                return $this->blockHandler->moveBlock(
                    $block,
                    $targetBlock,
                    $placeholder,
                    $position
                );
            }
        );
    }
private function internalMoveBlock(PersistenceBlock $block, PersistenceBlock $targetBlock, string $placeholder, int $position): PersistenceBlock
    {
        return $this->transaction(
            function () use ($block, $targetBlock, $placeholder, $position): PersistenceBlock {
                if ($block->parentId === $targetBlock->id && $block->placeholder === $placeholder) {
                    return $this->blockHandler->moveBlockToPosition($block, $position);
                }

                return $this->blockHandler->moveBlock(
                    $block,
                    $targetBlock,
                    $placeholder,
                    $position
                );
            }
        );
    }
private function internalMoveBlock ( PersistenceBlock $ block , PersistenceBlock $ targetBlock , string $ placeholder , int $ position ) : PersistenceBlock { return $ this -> transaction ( function ( ) use ( $ block , $ targetBlock , $ placeholder , $ position ) : PersistenceBlock { if ( $ block -> parentId === $ targetBlock -> id && $ block -> placeholder === $ placeholder ) { return $ this -> blockHandler -> moveBlockToPosition ( $ block , $ position ) ; } return $ this -> blockHandler -> moveBlock ( $ block , $ targetBlock , $ placeholder , $ position ) ; } ) ; }
Moves a block to specified target block and placeholder and position.

This is an internal method unifying moving a block to a zone and to a parent block.
Moves a block to specified target block and placeholder and position .