cache bug fix
This commit is contained in:
@@ -17,7 +17,8 @@ final class RecentArticles extends Controller
|
||||
*/
|
||||
public function __invoke()
|
||||
{
|
||||
return Cache::remember('articles.recent', 300, function () {
|
||||
$currentPage = request()->get('page',1);
|
||||
return Cache::remember('articles.recent_'.$currentPage, 300, function () {
|
||||
return [
|
||||
"articles" => Article::with('source', 'topics')
|
||||
->latest("published_date")
|
||||
|
Reference in New Issue
Block a user