The conn token returned from Conn.read_body/1 function should not be ignored as it may contain vital state regarding the connection which has been altered by this function.
For example when using bandit ignoring conn will cause the keepalive mechanism to malfunction! (See mtrudel/bandit#260)
From Plug.Conn.read_body docs:
Like all functions in this module, the conn returned by read_body must be passed to the next stage of your pipeline and should not be ignored.
The
conn
token returned fromConn.read_body/1
function should not be ignored as it may contain vital state regarding the connection which has been altered by this function.For example when using bandit ignoring conn will cause the keepalive mechanism to malfunction! (See mtrudel/bandit#260)
From
Plug.Conn.read_body
docs: