diff --git a/src/docs/asciidoc/web/webflux.adoc b/src/docs/asciidoc/web/webflux.adoc index 611cf6ba66..9e543d80b9 100644 --- a/src/docs/asciidoc/web/webflux.adoc +++ b/src/docs/asciidoc/web/webflux.adoc @@ -2975,7 +2975,7 @@ configure or customize message writing. public ResponseEntity handle() { String body = ... ; String etag = ... ; - return ResponseEntity.ok().eTag(etag).build(body); + return ResponseEntity.ok().eTag(etag).body(body); } ---- [source,kotlin,indent=0,subs="verbatim,quotes",role="secondary"] diff --git a/src/docs/asciidoc/web/webmvc.adoc b/src/docs/asciidoc/web/webmvc.adoc index 20964461ed..82efd4eeab 100644 --- a/src/docs/asciidoc/web/webmvc.adoc +++ b/src/docs/asciidoc/web/webmvc.adoc @@ -3386,7 +3386,7 @@ See <> for details. public ResponseEntity handle() { String body = ... ; String etag = ... ; - return ResponseEntity.ok().eTag(etag).build(body); + return ResponseEntity.ok().eTag(etag).body(body); } ---- [source,kotlin,indent=0,subs="verbatim,quotes",role="secondary"]