Skip to content

Commit 54d57f2

Browse files
committed
return only 5 post for now.
1 parent d4a7752 commit 54d57f2

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

app/Http/Controllers/PostController.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,7 @@ class PostController extends Controller
1616
*/
1717
public function index()
1818
{
19-
$post = Post::latest()->get();
19+
$post = Post::latest()->take(5)->get();;
2020
return PostResource::collection($post);
2121
}
2222

0 commit comments

Comments
 (0)