Refactor error handling and logging in API responses
This commit is contained in:
@ -67,7 +67,7 @@ case 'POST':
|
||||
}
|
||||
if (!$chkCoach->fetch()) {
|
||||
qdb_discard($tmpDb, $lockFp);
|
||||
json_error('NOT_FOUND', 'Coach not found or not authorized', 400);
|
||||
json_error('NOT_FOUND', 'Coach not found or not authorized', 404);
|
||||
}
|
||||
|
||||
$chk = $pdo->prepare("SELECT clientCode FROM client WHERE clientCode = :cc");
|
||||
|
||||
Reference in New Issue
Block a user