Skip to content
This repository has been archived by the owner on Dec 21, 2024. It is now read-only.

Commit

Permalink
feat(save): change save api validation
Browse files Browse the repository at this point in the history
  • Loading branch information
tikrack committed Sep 9, 2024
1 parent b128692 commit ce04427
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions app/Controllers/CodeController.php
Original file line number Diff line number Diff line change
Expand Up @@ -47,8 +47,8 @@ public function save(): void
{
$request = Flight::request()->data->getData();
$rules = [
'title' => ['required', 'string'],
'code' => ['required', 'string'],
'title' => ['required'],
'code' => ['required'],
];
$validator = new Validator($request, $rules);
$validator->validate();
Expand Down

0 comments on commit ce04427

Please sign in to comment.