Polish "Replace magic number by HttpStatus"

Closes gh-15130
This commit is contained in:
Stephane Nicoll 2018-12-03 15:33:57 +01:00
parent ffdc9f0ff3
commit f2ca2533d5

View File

@ -39,8 +39,9 @@ class TraceableServerHttpResponse implements TraceableResponse {
@Override @Override
public int getStatus() { public int getStatus() {
return (this.response.getStatusCode() != null) HttpStatus status = (this.response.getStatusCode() != null)
? this.response.getStatusCode().value() : HttpStatus.OK.value(); ? this.response.getStatusCode() : HttpStatus.OK;
return status.value();
} }
@Override @Override