Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 4 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -376,9 +376,7 @@ final class HotelController
$this->hotelRepository = $hotelRepository;
}

/**
* @Route("/create", methods={"POST"})
*/
#[Route("/create", methods:["POST"])]
public function createAction(Request $request): JsonResponse
{
$name = $request->request->get('name'); // need validation!
Expand All @@ -391,9 +389,7 @@ final class HotelController
return new JsonResponse(['id' => $id->toString()]);
}

/**
* @Route("/:id/check-in", methods={"POST"})
*/
#[Route("/:id/check-in", methods:["POST"])]
public function createAction(string $id, Request $request): JsonResponse
{
$id = Uuid::fromString($id);
Expand All @@ -405,10 +401,8 @@ final class HotelController

return new JsonResponse(['id' => $id->toString()]);
}

/**
* @Route("/:id/check-out", methods={"POST"})
*/

#[Route("/:id/check-out", methods:["POST"])]
public function createAction(string $id, Request $request): JsonResponse
{
$id = Uuid::fromString($id);
Expand Down
5 changes: 4 additions & 1 deletion docs/event_bus.md
Original file line number Diff line number Diff line change
Expand Up @@ -42,4 +42,7 @@ framework:
command.bus: ~
event.bus:
default_middleware: allow_no_handlers
```
```

> :warning: You should deactivate the autoconfigure feature for the handlers,
> otherwise they will be registered in both handlers.