X-Git-Url: https://git.immae.eu/?a=blobdiff_plain;f=src%2FWallabag%2FCoreBundle%2FController%2FEntryController.php;fp=src%2FWallabag%2FCoreBundle%2FController%2FEntryController.php;h=5407d06578780227fe4a18eacc8b69463955e057;hb=eb7b632ee6f898dbe5c861623f59fa62fc4d5235;hp=ff90957b9917661f879472a5186d28dea6ab26a1;hpb=96295ec84796551590d24a3516ccbba43469b6f6;p=github%2Fwallabag%2Fwallabag.git diff --git a/src/Wallabag/CoreBundle/Controller/EntryController.php b/src/Wallabag/CoreBundle/Controller/EntryController.php index ff90957b..5407d065 100644 --- a/src/Wallabag/CoreBundle/Controller/EntryController.php +++ b/src/Wallabag/CoreBundle/Controller/EntryController.php @@ -532,9 +532,9 @@ class EntryController extends Controller $searchTerm = (isset($request->get('search_entry')['term']) ? $request->get('search_entry')['term'] : ''); $currentRoute = (null !== $request->query->get('currentRoute') ? $request->query->get('currentRoute') : ''); - $sortBy = 'id'; - if (in_array($request->get('sort', 'id'), ['id', 'created_at', 'title', 'updated_at'], true)) { - $sortBy = $request->get('sort', 'id'); + $sortBy = 'createdAt'; + if (in_array($request->get('sort', 'createdAt'), ['id', 'createdAt', 'title', 'updatedAt'], true)) { + $sortBy = $request->get('sort', 'createdAt'); } $direction = 'DESC' === $request->get('direction') ? 'DESC' : 'ASC';