@recaptime-dev's working patches + fork for Phorge, a community fork of Phabricator. (Upstream dev and stable branches are at upstream/main and upstream/stable respectively.) hq.recaptime.dev/wiki/Phorge
phorge phabricator
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Fix an exception in cursor pagination of Conpherence threads

Summary: Ref T13680. Conpherence may pass values with an integer type to this layer of the stack. These are "supposed" to be strings, but just be accepting.

Test Plan:
- Wrote 100+ messages to a Conpherence room.
- Clicked "Show Older Messages".
- Before: exception, int passed to "phutil_nonempty_string()".
- After: older messages loaded.

Maniphest Tasks: T13680

Differential Revision: https://secure.phabricator.com/D21824

+7 -4
+7 -4
src/infrastructure/query/policy/PhabricatorCursorPagedPolicyAwareQuery.php
··· 369 369 370 370 $this->setLimit($limit + 1); 371 371 372 - if (phutil_nonempty_string($pager->getAfterID())) { 373 - $this->setExternalCursorString($pager->getAfterID()); 374 - } else if ($pager->getBeforeID()) { 375 - $this->setExternalCursorString($pager->getBeforeID()); 372 + $after_id = phutil_string_cast($pager->getAfterID()); 373 + $before_id = phutil_string_cast($pager->getBeforeID()); 374 + 375 + if (phutil_nonempty_string($after_id)) { 376 + $this->setExternalCursorString($after_id); 377 + } else if (phutil_nonempty_string($before_id)) { 378 + $this->setExternalCursorString($before_id); 376 379 $this->setIsQueryOrderReversed(true); 377 380 } 378 381