pull/9/head
tanghc 4 years ago
parent 2243a93f5b
commit 13e30c87b6
  1. 1
      sop-common/sop-gateway-common/src/main/java/com/gitee/sop/gatewaycommon/gateway/controller/GatewayController.java

@ -39,6 +39,7 @@ public class GatewayController {
ApiException exception = ErrorEnum.ISV_INVALID_METHOD.getErrorMeta().getException(); ApiException exception = ErrorEnum.ISV_INVALID_METHOD.getErrorMeta().getException();
ResultExecutor<ServerWebExchange, String> resultExecutor = ApiContext.getApiConfig().getGatewayResultExecutor(); ResultExecutor<ServerWebExchange, String> resultExecutor = ApiContext.getApiConfig().getGatewayResultExecutor();
String gatewayResult = resultExecutor.buildErrorResult(exchange, exception); String gatewayResult = resultExecutor.buildErrorResult(exchange, exception);
exchange.getResponse().getHeaders().add(HttpHeaders.CONTENT_TYPE, MediaType.APPLICATION_JSON_VALUE);
return Mono.just(gatewayResult); return Mono.just(gatewayResult);
} }

Loading…
Cancel
Save