src/PHPDish/Bundle/PostBundle/Service/BookManager.php
public function moveBookChapter(BookInterface $book, ChapterInterface $chapter, $direction, $step)
    {
        $func = $direction === static::MOVE_DIRECTION_UP ? 'moveUp' : 'moveDown';

        $this->postManager->getPostRepository()->$func($chapter, $step);

//        $this->entityManager->clear();
    }
public function moveBookChapter(BookInterface $book, ChapterInterface $chapter, $direction, $step)
    {
        $func = $direction === static::MOVE_DIRECTION_UP ? 'moveUp' : 'moveDown';

        $this->postManager->getPostRepository()->$func($chapter, $step);

//        $this->entityManager->clear();
    }
{@inheritdoc}