@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.

Correct an issue with epoch timestamps in Conduit

Summary:
Fixes T11375. Some validation code was mishandling raw epoch timestamps.

For numeric values larger than 29999999 (e.g., 2999-12-25, christmas 2999), assume the value is a timestamp.

Test Plan: Used `maniphest.search` to query for `modifiedStart`, got a better result set and saw the `dateModified` constraint in the query.

Reviewers: chad

Reviewed By: chad

Maniphest Tasks: T11375

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

+8
+8
src/applications/search/field/PhabricatorSearchDateField.php
··· 35 35 return null; 36 36 } 37 37 38 + // If this appears to be an epoch timestamp, just return it unmodified. 39 + // This assumes values like "2016" or "20160101" are "Ymd". 40 + if (is_int($value) || ctype_digit($value)) { 41 + if ((int)$value > 30000000) { 42 + return (int)$value; 43 + } 44 + } 45 + 38 46 return PhabricatorTime::parseLocalTime($value, $this->getViewer()); 39 47 } 40 48