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

Fix a f()[0] use in rPd45855e33e0b98d521ea3e44a4c1f718821ec6cc

Summary: See D3291.

Test Plan: Ran `phpast.getast` via API.

Reviewers: alanh

Reviewed By: alanh

CC: aran

Differential Revision: https://secure.phabricator.com/D3292
This commit is contained in:
epriestley 2012-08-15 04:36:41 -07:00
parent f736ca047a
commit f0be29649d

View file

@ -42,8 +42,11 @@ final class ConduitAPI_phpast_getast_Method extends ConduitAPIMethod {
}
protected function execute(ConduitAPIRequest $request) {
return json_decode(
xhpast_get_parser_future($request->getValue('code'))->resolvex()[0]);
$source = $request->getValue('code');
$future = xhpast_get_parser_future($source);
list($stdout) = $future->resolvex();
return json_decode($stdout, true);
}
}