Commit b86f7833 authored by Andrea Ruggiero's avatar Andrea Ruggiero
Browse files

Fix

parent 045b6afa
Pipeline #1537 failed with stage
in 0 seconds
......@@ -27,7 +27,7 @@ class EventController extends Controller
$user = $sessionRepository->getUserByToken($request->headers->get('X-Auth-Token'));
foreach ($events as $event) {
$response[] = [
$temp = [
"id" => $event->event_id,
"title" => $event->title,
"speaker" => $event->speaker,
......@@ -44,6 +44,8 @@ class EventController extends Controller
if ($user !== null) {
$response["hasBooked"] = $bookingRepository->getBookingByEventAndUser($user->user_id, $event->event_id) !== null;
}
$response[] = $temp;
}
return ApiResponse::success($response);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment