1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-10 00:42:41 +01:00

Fix default order for Differential queries

Summary:
Fixes T3781. The UI defaults to "Created" but the query defaults to "Modified". Make the two consistent.

In particular, an issue this fixes is that previously a `/differential/?authors=duck` page would show "Order: Created" but actually order by "Modified".

Test Plan: Visited `/differential/?authors=duck` and verified the revisions were ordered by creation date.

Reviewers: btrahan

Reviewed By: btrahan

CC: aran

Maniphest Tasks: T3781

Differential Revision: https://secure.phabricator.com/D6843
This commit is contained in:
epriestley 2013-08-29 15:07:30 -07:00
parent eb32b5c812
commit 63dbccb8a1

View file

@ -82,6 +82,8 @@ final class DifferentialRevisionSearchEngine
$order = $saved->getParameter('order');
if (idx($this->getOrderOptions(), $order)) {
$query->setOrder($order);
} else {
$query->setOrder(DifferentialRevisionQuery::ORDER_CREATED);
}
return $query;