Changeset View
Changeset View
Standalone View
Standalone View
src/aphront/response/AphrontJSONResponse.php
| <?php | <?php | ||||
| /** | |||||
| * @group aphront | |||||
| */ | |||||
| final class AphrontJSONResponse extends AphrontResponse { | final class AphrontJSONResponse extends AphrontResponse { | ||||
| private $content; | private $content; | ||||
| private $addJSONShield; | private $addJSONShield; | ||||
| public function setContent($content) { | public function setContent($content) { | ||||
| $this->content = $content; | $this->content = $content; | ||||
| return $this; | return $this; | ||||
| Show All 21 Lines | final class AphrontJSONResponse extends AphrontResponse { | ||||
| public function getHeaders() { | public function getHeaders() { | ||||
| $headers = array( | $headers = array( | ||||
| array('Content-Type', 'application/json'), | array('Content-Type', 'application/json'), | ||||
| ); | ); | ||||
| $headers = array_merge(parent::getHeaders(), $headers); | $headers = array_merge(parent::getHeaders(), $headers); | ||||
| return $headers; | return $headers; | ||||
| } | } | ||||
| } | } | ||||