Skip to content

Commit 49104b8

Browse files
author
Nakul Sabharwal
committed
UnsupportedEncodingException is being further handled in function sendRequestInternal of DefaultHttpProvider.
1 parent 4674772 commit 49104b8

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

src/main/java/com/microsoft/graph/http/DefaultHttpProvider.java

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -407,14 +407,16 @@ private <Result> Result handleJsonResponse(final InputStream in, Map<String, Lis
407407
* @param clazz the type of the response object
408408
* @return the JSON object
409409
*/
410-
private <Result> Result handleEmptyResponse(Map<String, List<String>> responseHeaders, final Class<Result> clazz) {
410+
private <Result> Result handleEmptyResponse(Map<String, List<String>> responseHeaders, final Class<Result> clazz)
411+
throws UnsupportedEncodingException{
411412
//Create an empty object to attach the response headers to
412413
InputStream in = null;
413414
try{
414415
in = new ByteArrayInputStream("{}".getBytes(ENCODING_TYPE));
415416
}
416417
catch(UnsupportedEncodingException ex) {
417418
logger.logError(ex.getMessage(), ex);
419+
throw ex;
418420
}
419421

420422
return handleJsonResponse(in, responseHeaders, clazz);

0 commit comments

Comments
 (0)