1
0
mirror of https://github.com/invoiceninja/invoiceninja.git synced 2024-11-13 22:54:25 +01:00
invoiceninja/app/Ninja/Serializers/ArraySerializer.php

19 lines
548 B
PHP
Raw Normal View History

2015-11-01 23:10:20 +01:00
<?php namespace App\Ninja\Serializers;
use League\Fractal\Serializer\ArraySerializer as FractalArraySerializer;
class ArraySerializer extends FractalArraySerializer
{
public function collection($resourceKey, array $data)
{
2015-12-14 21:07:48 +01:00
return $data;
//return ($resourceKey && $resourceKey !== 'data') ? array($resourceKey => $data) : $data;
2015-11-01 23:10:20 +01:00
}
public function item($resourceKey, array $data)
{
2015-12-14 21:07:48 +01:00
return $data;
//return ($resourceKey && $resourceKey !== 'data') ? array($resourceKey => $data) : $data;
2015-11-01 23:10:20 +01:00
}
}