1
0
mirror of https://github.com/flarum/core.git synced 2025-10-13 07:54:25 +02:00

Get rid of JsonApiResponse class

With the JSON-API library being updated, we can just make use of
Diactoros' JSON response class.
This commit is contained in:
Franz Liedke
2015-07-01 20:58:14 +02:00
parent 7054472d66
commit ccbebce93b
2 changed files with 2 additions and 18 deletions

View File

@@ -1,14 +0,0 @@
<?php namespace Flarum\Api;
use Tobscure\JsonApi\Document;
use Zend\Diactoros\Response;
class JsonApiResponse extends Response
{
public function __construct(Document $document)
{
parent::__construct('php://memory', 200, ['content-type' => 'application/vnd.api+json']);
$this->getBody()->write($document);
}
}