@@ -123,13 +123,13 @@ type readerOnError struct {
123123}
124124
125125// NewReaderOnError returns a io.Reader that call the notify function when an
126- // unexpected (!io.EOF) error happends , after call Read function.
126+ // unexpected (!io.EOF) error happens , after call Read function.
127127func NewReaderOnError (r io.Reader , notify func (error )) io.Reader {
128128 return & readerOnError {r , notify }
129129}
130130
131131// NewReadCloserOnError returns a io.ReadCloser that call the notify function
132- // when an unexpected (!io.EOF) error happends , after call Read function.
132+ // when an unexpected (!io.EOF) error happens , after call Read function.
133133func NewReadCloserOnError (r io.ReadCloser , notify func (error )) io.ReadCloser {
134134 return NewReadCloser (NewReaderOnError (r , notify ), r )
135135}
@@ -149,13 +149,13 @@ type writerOnError struct {
149149}
150150
151151// NewWriterOnError returns a io.Writer that call the notify function when an
152- // unexpected (!io.EOF) error happends , after call Write function.
152+ // unexpected (!io.EOF) error happens , after call Write function.
153153func NewWriterOnError (w io.Writer , notify func (error )) io.Writer {
154154 return & writerOnError {w , notify }
155155}
156156
157157// NewWriteCloserOnError returns a io.WriteCloser that call the notify function
158- //when an unexpected (!io.EOF) error happends , after call Write function.
158+ //when an unexpected (!io.EOF) error happens , after call Write function.
159159func NewWriteCloserOnError (w io.WriteCloser , notify func (error )) io.WriteCloser {
160160 return NewWriteCloser (NewWriterOnError (w , notify ), w )
161161}
0 commit comments