src/Extensions/CommentsExtension.php
public function PagedComments()
    {
        $list = $this->Comments();

        // Add pagination
        $list = PaginatedList::create($list, Controller::curr()->getRequest());
        $list->setPaginationGetVar('commentsstart' . $this->owner->ID);
        $list->setPageLength($this->owner->getCommentsOption('comments_per_page'));

        $this->owner->extend('updatePagedComments', $list);
        return $list;
    }
public function PagedComments()
    {
        $list = $this->Comments();

        // Add pagination
        $list = PaginatedList::create($list, Controller::curr()->getRequest());
        $list->setPaginationGetVar('commentsstart' . $this->owner->ID);
        $list->setPageLength($this->owner->getCommentsOption('comments_per_page'));

        $this->owner->extend('updatePagedComments', $list);
        return $list;
    }
public function PagedComments ( ) { $ list = $ this -> Comments ( ) ; // Add pagination $ list = PaginatedList :: create ( $ list , Controller :: curr ( ) -> getRequest ( ) ) ; $ list -> setPaginationGetVar ( 'commentsstart' . $ this -> owner -> ID ) ; $ list -> setPageLength ( $ this -> owner -> getCommentsOption ( 'comments_per_page' ) ) ; $ this -> owner -> extend ( 'updatePagedComments' , $ list ) ; return $ list ; }
Returns a paged list of the root level comments, with spam and unmoderated items excluded,
for use in the frontend

@return PaginatedList
Returns a paged list of the root level comments with spam and unmoderated items excluded for use in the frontend