Skip to content

Commit

Permalink
Merge pull request #19 from whernandez/bug/push-response
Browse files Browse the repository at this point in the history
Add mapping property to the response
  • Loading branch information
angelbencosme authored Jul 19, 2023
2 parents 8b8d142 + d0dbcfa commit 4a9e26b
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion Controller/SyncController.php
Original file line number Diff line number Diff line change
Expand Up @@ -83,7 +83,9 @@ public function pushAction(Request $request)
try {
$data = json_decode($request->getContent(), true);
$result = $this->pushService->push($data);
return new JsonResponse($result, 200);
return new JsonResponse(array(
"mappings" => $result
), 200);
} catch (\Exception $e) {
return new JsonResponse($e->getMessage(), 500);
}
Expand Down

0 comments on commit 4a9e26b

Please sign in to comment.