Skip to content

Commit 7a8f270

Browse files
Added HTTP not found
1 parent 363126b commit 7a8f270

1 file changed

Lines changed: 1 addition & 5 deletions

File tree

api/src/main/java/ca/bc/gov/educ/api/graduation/service/GraduationService.java

Lines changed: 1 addition & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -144,12 +144,8 @@ public byte[] prepareTranscriptReport(String pen, String interim, String preview
144144
try {
145145
return restService.post(educGraduationApiConstants.getTranscriptReport(), reportParams, byte[].class, graduationApiClient);
146146
} catch (ServiceException ex) {
147-
if(HttpStatus.NO_CONTENT.value() == ex.getStatusCode()){
147+
if(HttpStatus.NO_CONTENT.value() == ex.getStatusCode() || HttpStatus.NOT_FOUND.value() == ex.getStatusCode()){
148148
return new byte[0];
149-
} else if(HttpStatus.NOT_FOUND.value() == ex.getStatusCode()) {
150-
throw new EntityNotFoundException(
151-
GraduationService.class,
152-
"No report found for student " + reportParams);
153149
} else {
154150
throw ex;
155151
}

0 commit comments

Comments
 (0)