Skip to content

Commit

Permalink
Handle null
Browse files Browse the repository at this point in the history
Signed-off-by: Craig Perkins <[email protected]>
  • Loading branch information
cwperks committed Aug 27, 2024
1 parent e6b82ba commit bc610a2
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion server/src/main/java/org/opensearch/rest/RestController.java
Original file line number Diff line number Diff line change
Expand Up @@ -131,7 +131,11 @@ public RestController(
) {
this.headersToCopy = headersToCopy;
this.usageService = usageService;
this.handlerWrapper = handlerWrapper;
if (handlerWrapper == null) {
this.handlerWrapper = PASS_THROUGH_REST_HANDLER_WRAPPER;
} else {
this.handlerWrapper = handlerWrapper;
}
this.client = client;
this.circuitBreakerService = circuitBreakerService;
registerHandlerNoWrap(
Expand Down

0 comments on commit bc610a2

Please sign in to comment.