Skip to content
This repository has been archived by the owner on Sep 15, 2023. It is now read-only.

Commit

Permalink
Log exception and fix != 400
Browse files Browse the repository at this point in the history
  • Loading branch information
UBaggeler committed Jul 6, 2021
1 parent 935c577 commit e0a0b01
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -46,13 +46,13 @@ private VerificationResponse verify(HCertPayload hCertPayload) {
.POST(BodyPublishers.ofString(hCert))
.build();
final HttpResponse<String> response = httpClient.send(request, BodyHandlers.ofString());
if (response.statusCode() != 400) {
if (response.statusCode() == 400) {
logger.info("Certificate couldn't be decoded.");
return null;
}
return objectMapper.readValue(response.body(), VerificationResponse.class);
} catch (URISyntaxException | IOException | InterruptedException e) {
logger.error("Couldn't verify certificate");
logger.error("Couldn't verify certificate", e);
return null;
}
}
Expand Down

0 comments on commit e0a0b01

Please sign in to comment.