Vapor v4.0.2 Release Notes

Release Date: 2020-04-14 // about 4 years ago
  • ๐Ÿš€ ###### This patch was authored and released by @tanner0101.

    ๐Ÿ‘Œ Improves logic for handling HEAD responses (#2310).

    Previously when HEAD requests were detected, the response body would be replaced with an empty body and the content-length header would be re-added. This caused problems with responses that don't use the content-length header, even for non-HEAD requests.

    ๐Ÿšฆ Now, when HEAD requests are detected, the response body is not changed. Instead, a flag is set signaling the serializer to skip serialization of the body.