laravel get last record
snippet in php

laravel get last record

user6072

Model::latest()->first();

laravel get last record

user2602

return DB::table('files')->order_by('upload_time', 'desc')->first();