Skip to content

Commit

Permalink
Update (#6)
Browse files Browse the repository at this point in the history
* fix: Avoid redirects without 3xx status code

* chore(test): Fix make target

* chore(cs): Newline at EOF

* fix(dev): Redis host at Docker environment

* chore(deps): Bump

* Setup gatling

---------

Co-authored-by: leocavalcante <lc@leocavalcante.com>
Co-authored-by: William Correa <william.correa@picpay.com>
Co-authored-by: Diego Ferreira <diegoferreira@PPM-SPO-015219.local>
  • Loading branch information
4 people committed Aug 19, 2023
1 parent 8abcb5f commit 87f7517
Show file tree
Hide file tree
Showing 3 changed files with 81 additions and 28 deletions.
2 changes: 1 addition & 1 deletion app/Controller/PersonController.php
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ public function create(PersonRequest $request, ResponseInterface $response): Mes
$this->cache->set($person['nick'], '.');
$this->cache->set($person['id'], json_encode($person));

return $response->json($person)->withStatus(201)->withHeader('Location', "/pessoas/{$person['id']}");
return $response->json($person)->withStatus(201);
}

public function show(RequestInterface $request, ResponseInterface $response, string $id): MessageResponseInterface
Expand Down
104 changes: 78 additions & 26 deletions composer.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 2 additions & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,6 +10,7 @@ services:
APP_STAGE: dev
environment:
DB_HOST: db
REDIS_HOST: cache
volumes:
- ./:/opt/www
depends_on:
Expand Down Expand Up @@ -71,4 +72,4 @@ services:

networks:
default:
name: rinha-de-backend
name: rinha-de-backend

0 comments on commit 87f7517

Please sign in to comment.