1
0
Fork 0
mirror of https://we.phorge.it/source/phorge.git synced 2024-11-20 13:52:40 +01:00

Disable JSON shield for uncaught exception responses to Conduit requests

Summary: Modern conduit responses should never have a JSON shield. We disable it for normal responses, but uncaught exceptions hit this higher-level handler block which fails to disable the shield. Disable the shield.

Test Plan: Inspection.

Reviewers: btrahan, andrewjcg

Reviewed By: andrewjcg

CC: aran, Korvin

Differential Revision: https://secure.phabricator.com/D5483
This commit is contained in:
epriestley 2013-03-30 19:04:40 -07:00
parent e80c59cbc6
commit 41b32d5fbe

View file

@ -137,6 +137,7 @@ class AphrontDefaultApplicationConfiguration
$response->setErrorInfo($ex->getMessage());
return id(new AphrontJSONResponse())
->setAddJSONShield(false)
->setContent($response->toDictionary());
}