Skip to content

Commit

Permalink
Fix for URL generation. Does not ignore URL parts
Browse files Browse the repository at this point in the history
  • Loading branch information
nilportugues committed Jun 27, 2016
1 parent f6d23f5 commit 177c14d
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 6 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -11,8 +11,6 @@
namespace NilPortugues\Laravel5\JsonApi\Controller;

use Illuminate\Routing\Controller;
use Illuminate\Container\Container;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Http\Request;
use NilPortugues\Api\JsonApi\Http\Factory\RequestFactory;
use NilPortugues\Api\JsonApi\Http\Response\ResourceNotFound;
Expand Down Expand Up @@ -100,6 +98,7 @@ public function store(Request $request)
{
$createResource = $this->createResourceCallable();
$resource = new CreateResource($this->serializer);

return $this->addHeaders(
$resource->get((array) $request->get('data'), get_class($this->getDataModel()), $createResource)
);
Expand Down
4 changes: 0 additions & 4 deletions src/NilPortugues/Laravel5/JsonApi/Controller/JsonApiTrait.php
Original file line number Diff line number Diff line change
Expand Up @@ -13,10 +13,6 @@
use Illuminate\Container\Container;
use Illuminate\Database\Eloquent\Model;
use Illuminate\Http\Request;
use NilPortugues\Laravel5\JsonApi\Actions\CreateResource;
use NilPortugues\Laravel5\JsonApi\Actions\DeleteResource;
use NilPortugues\Laravel5\JsonApi\Actions\GetResource;
use NilPortugues\Laravel5\JsonApi\Actions\ListResource;
use NilPortugues\Laravel5\JsonApi\Actions\PatchResource;
use NilPortugues\Laravel5\JsonApi\Actions\PutResource;
use NilPortugues\Api\JsonApi\Server\Errors\Error;
Expand Down

0 comments on commit 177c14d

Please sign in to comment.