private function getNextUrl(PaginatorInterface $paginator) : ?string
    {
        $page = $paginator->getCurrentPage();

        if (++$page <= $paginator->getAvailablePages()) {
            return $this->generateUrl(
                $this->getRoute(),
                $this->getMergedParams(['page' => $page])
            );
        }

        return null;
    }
private function getNextUrl(PaginatorInterface $paginator) : ?string
    {
        $page = $paginator->getCurrentPage();

        if (++$page <= $paginator->getAvailablePages()) {
            return $this->generateUrl(
                $this->getRoute(),
                $this->getMergedParams(['page' => $page])
            );
        }

        return null;
    }
private function getNextUrl ( PaginatorInterface $ paginator ) : ? string { $ page = $ paginator -> getCurrentPage ( ) ; if ( ++ $ page <= $ paginator -> getAvailablePages ( ) ) { return $ this -> generateUrl ( $ this -> getRoute ( ) , $ this -> getMergedParams ( [ 'page' => $ page ] ) ) ; } return null ; }
Get next URL

@param PaginatorInterface $paginator

@return string|null
Get next URL