diff --git a/src/view/control/idpager/AphrontIDPagerView.php b/src/view/control/idpager/AphrontIDPagerView.php index 3f455caa07..4f7486d59b 100644 --- a/src/view/control/idpager/AphrontIDPagerView.php +++ b/src/view/control/idpager/AphrontIDPagerView.php @@ -87,7 +87,8 @@ final class AphrontIDPagerView extends AphrontView { final public function sliceResults(array $results) { if (count($results) > $this->getPageSize()) { - $results = array_slice($results, 0, $this->getPageSize(), true); + $offset = ($this->beforeID ? count($results) - $this->getPageSize() : 0); + $results = array_slice($results, $offset, $this->getPageSize(), true); } return $results; }