From ffdc9f0ff3927057f00c6ca2b098c4280efda090 Mon Sep 17 00:00:00 2001 From: holy12345 Date: Thu, 8 Nov 2018 16:16:06 +0800 Subject: [PATCH] Replace magic number by HttpStatus See gh-15130 --- .../web/trace/reactive/TraceableServerHttpResponse.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/spring-boot-project/spring-boot-actuator/src/main/java/org/springframework/boot/actuate/web/trace/reactive/TraceableServerHttpResponse.java b/spring-boot-project/spring-boot-actuator/src/main/java/org/springframework/boot/actuate/web/trace/reactive/TraceableServerHttpResponse.java index db1f44c71c..40f839463a 100644 --- a/spring-boot-project/spring-boot-actuator/src/main/java/org/springframework/boot/actuate/web/trace/reactive/TraceableServerHttpResponse.java +++ b/spring-boot-project/spring-boot-actuator/src/main/java/org/springframework/boot/actuate/web/trace/reactive/TraceableServerHttpResponse.java @@ -21,6 +21,7 @@ import java.util.List; import java.util.Map; import org.springframework.boot.actuate.trace.http.TraceableResponse; +import org.springframework.http.HttpStatus; import org.springframework.http.server.reactive.ServerHttpResponse; /** @@ -39,7 +40,7 @@ class TraceableServerHttpResponse implements TraceableResponse { @Override public int getStatus() { return (this.response.getStatusCode() != null) - ? this.response.getStatusCode().value() : 200; + ? this.response.getStatusCode().value() : HttpStatus.OK.value(); } @Override