Reversed the order in which albums are loaded from the database
This commit is contained in:
parent
6338aa4554
commit
03446c0cbd
@ -2,7 +2,7 @@
|
|||||||
|
|
||||||
$app->get('/music', function() use($app) {
|
$app->get('/music', function() use($app) {
|
||||||
|
|
||||||
$albums = $app->album->all();
|
$albums = $app->album->all()->sortByDesc('release_date')->values()->all();
|
||||||
$songs = $albums[0]->songs;
|
$songs = $albums[0]->songs;
|
||||||
|
|
||||||
$app->render('music.twig', [
|
$app->render('music.twig', [
|
||||||
|
Loading…
Reference in New Issue
Block a user