mirror of
https://we.phorge.it/source/phorge.git
synced 2025-01-31 08:58:20 +01:00
Fix a lisk issue
Summary: This was broken in D12680. ``` EXCEPTION: (PhutilJSONParserException) Parse error on line 0 at column 0: 'null' is not a valid JSON object. at [<phutil>/src/parser/PhutilJSONParser.php:41] #0 PhutilJSONParser::parse(string) called at [<phutil>/src/utils/utils.php:1062] #1 phutil_json_decode(string) called at [<phabricator>/src/infrastructure/storage/lisk/LiskDAO.php:1640] #2 LiskDAO::applyLiskDataSerialization(array, boolean) called at [<phabricator>/src/infrastructure/storage/lisk/LiskDAO.php:1386] #3 LiskDAO::willReadData(array) called at [<phabricator>/src/infrastructure/storage/lisk/PhabricatorLiskDAO.php:214] #4 PhabricatorLiskDAO::willReadData(array) called at [<phabricator>/src/infrastructure/storage/lisk/LiskDAO.php:608] #5 LiskDAO::loadFromArray(array) called at [<phabricator>/src/infrastructure/storage/lisk/LiskDAO.php:652] #6 LiskDAO::loadAllFromArray(array) called at [<phabricator>/src/applications/transactions/query/PhabricatorApplicationTransactionQuery.php:62] #7 PhabricatorApplicationTransactionQuery::loadPage() called at [<phabricator>/src/infrastructure/query/policy/PhabricatorPolicyAwareQuery.php:227] #8 PhabricatorPolicyAwareQuery::execute() called at [<phabricator>/src/infrastructure/query/policy/PhabricatorCursorPagedPolicyAwareQuery.php:143] #9 PhabricatorCursorPagedPolicyAwareQuery::executeWithCursorPager(AphrontCursorPagerView) called at [<phabricator>/src/applications/base/controller/PhabricatorController.php:577] #10 PhabricatorController::buildTransactionTimeline(PhabricatorPaste, PhabricatorPasteTransactionQuery) called at [<phabricator>/src/applications/paste/controller/PhabricatorPasteViewControll ``` Test Plan: No exception shown. Reviewers: epriestley, #blessed_reviewers Reviewed By: epriestley, #blessed_reviewers Subscribers: Korvin, epriestley Differential Revision: https://secure.phabricator.com/D12714
This commit is contained in:
parent
ec22df5e17
commit
8d128646b3
1 changed files with 1 additions and 1 deletions
|
@ -1637,7 +1637,7 @@ abstract class LiskDAO {
|
||||||
break;
|
break;
|
||||||
case self::SERIALIZATION_JSON:
|
case self::SERIALIZATION_JSON:
|
||||||
if ($deserialize) {
|
if ($deserialize) {
|
||||||
$data[$col] = phutil_json_decode($data[$col]);
|
$data[$col] = json_decode($data[$col], true);
|
||||||
} else {
|
} else {
|
||||||
$data[$col] = json_encode($data[$col]);
|
$data[$col] = json_encode($data[$col]);
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue