I'm retrieving data using the get() method in a Laravel controller. If the result turns out to be empty, how can I verify this condition and proceed with the next step accordingly?
Here's the code snippet I'm currently working with:
$bookingLists = Booking::where(['bookings.user_id' => $user_id,'bookings.status' => $bStatus ])->get(); if(empty($bookingLists)){ }else{ }