Skip to content

Commit

Permalink
Updating redirect method to use built in URL. Updates #11
Browse files Browse the repository at this point in the history
  • Loading branch information
Jack Whiting committed May 23, 2019
1 parent ead672e commit 5c7e7bb
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "jackabox/nova-duplicate-field",
"description": "A Laravel Nova field to duplicate records.",
"version": "0.2.6",
"version": "0.2.7",
"keywords": [
"laravel",
"nova",
Expand Down
2 changes: 1 addition & 1 deletion src/Http/Controllers/DuplicateController.php
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ public function duplicate(Request $request)
return [
'status' => 200,
'message' => 'Done',
'destination' => 'http://' . $_SERVER['HTTP_HOST'] . '/' . config('nova.path') . '/resources/' . $request->resource . '/' . $newModel->id
'destination' => url(config('nova.path') . '/resources/' . $request->resource . '/' . $newModel->id)
];
}
}

0 comments on commit 5c7e7bb

Please sign in to comment.