diff --git a/docs/root/configuration/http/http_filters/lua_filter.rst b/docs/root/configuration/http/http_filters/lua_filter.rst index 3557adc74803..72b0e581d606 100644 --- a/docs/root/configuration/http/http_filters/lua_filter.rst +++ b/docs/root/configuration/http/http_filters/lua_filter.rst @@ -365,8 +365,10 @@ trailers() local trailers = handle:trailers() -Returns the stream's trailers. May return nil if there are no trailers. The trailers may be -modified before they are sent to the next filter. +Returns the stream's trailers. Before calling this method, the caller should call ``body()`` or +``bodyChunks()`` to consume the body, otherwise the trailers will not be available. +May return nil if there are no trailers. The trailers may be modified before they are sent +to the next filter. Returns a :ref:`header object `.