Path: blob/master/src/applications/diffusion/response/DiffusionGitLFSResponse.php
12241 views
<?php12final class DiffusionGitLFSResponse extends AphrontResponse {34private $content;56public static function newErrorResponse($code, $message) {78// We can optionally include "request_id" and "documentation_url" in9// this response.1011return id(new self())12->setHTTPResponseCode($code)13->setContent(14array(15'message' => $message,16));17}1819public function setContent(array $content) {20$this->content = phutil_json_encode($content);21return $this;22}2324public function buildResponseString() {25return $this->content;26}2728public function getHeaders() {29$headers = array(30array('Content-Type', 'application/vnd.git-lfs+json'),31);3233return array_merge(parent::getHeaders(), $headers);34}3536}373839