docs: improve ambiguous comment in c.Stream

This commit is contained in:
KevinZønda 2023-05-04 15:27:54 +01:00 committed by GitHub
parent eac2daac64
commit 4d47c2afd7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 3 additions and 1 deletions

View File

@ -1072,7 +1072,9 @@ func (c *Context) SSEvent(name string, message any) {
}
// Stream sends a streaming response and returns a boolean
// indicates "Is client disconnected in middle of stream"
// indicates "Will the client be connected in middle of stream"
// i.e. if return true, the client will keep connected
// if return false, the client will be disconnected
func (c *Context) Stream(step func(w io.Writer) bool) bool {
w := c.Writer
clientGone := w.CloseNotify()