add check jsonbody for request
Test Workflow / test (push) Successful in 4s

This commit is contained in:
vladp
2025-12-10 19:25:45 +07:00
parent a30b0488e8
commit 0635b9b4ac
2 changed files with 8 additions and 1 deletions
@@ -66,7 +66,13 @@ public class ApiController {
throw e;
} catch (Exception e) {
log.error("Handler execution failed for msgId: {}", msgId, e);
throw new RuntimeException("Handler execution failed", e);
BaseResponse errorResponse = new BaseResponse(msgId,
MessageCode.INVALID_JSON_BODY.getCode(),
MessageCode.INVALID_JSON_BODY.getDescription(),
new HashMap<>());
return ResponseEntity.ok().body(errorResponse);
}
}