We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 224171e commit c7fa7b3Copy full SHA for c7fa7b3
app/routes.php
@@ -3,9 +3,11 @@
3
declare(strict_types=1);
4
5
use App\Action\User\UserCreateAction;
6
+use App\Action\User\UserReadAction;
7
use Slim\App;
8
9
return function (App $app) {
10
$app->get('/', \App\Action\HomeAction::class)->setName('home');
11
$app->post('/users', UserCreateAction::class);
12
+ $app->get('/users/{id}', UserReadAction::class);
13
};
src/Action/HomeAction.php
@@ -19,6 +19,6 @@ public function __invoke(
19
20
return $response
21
->withHeader('Content-Type', 'application/json')
22
- ->withStatus(StatusCode::CREATED);
+ ->withStatus(StatusCode::OK);
23
}
24
0 commit comments