Skip to content

Commit

Permalink
Merge pull request #2125 from RakhithaRR/AI-5221
Browse files Browse the repository at this point in the history
Add a null check for response message context to skip engaging interceptors
  • Loading branch information
RakhithaRR authored Jan 10, 2024
2 parents 50f74e7 + 905bf5d commit b60f5f2
Showing 1 changed file with 2 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -624,7 +624,8 @@ public void inputReady(NHttpClientConnection conn, ContentDecoder decoder) {
int responseRead = -1;
boolean interceptionEnabled = false;
Boolean[] interceptorResults = new Boolean[noOfInterceptors];
if (interceptStream) {
if (conn.getContext().getAttribute(PassThroughConstants.RESPONSE_MESSAGE_CONTEXT) != null
&& interceptStream) {
int index = 0;
for (StreamInterceptor interceptor : streamInterceptors) {
interceptorResults[index] = interceptor.interceptTargetResponse(
Expand Down

0 comments on commit b60f5f2

Please sign in to comment.