Is there an equivalent to register_after_send?

Additionally, when calling send_resp directly, everything works from the client’s perspective, but the Phoenix app reports an error:

[error] ** (Plug.Conn.NotSentError) a response was neither set nor sent from the connection

In the documentation for Conn send_resp, it notes that one should call halt/1, but neither doing this nor not doing this prevent the error.