pkg/ioutils: remove errWriteFlusherClosed

It's an alias for io.EOF and not exported, so we don't need it.

Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
This commit is contained in:
Sebastiaan van Stijn
2025-01-09 16:21:33 +01:00
parent 034cd27da0
commit cdd4a7429f

View File

@@ -21,12 +21,10 @@ type flusher interface {
Flush()
}
var errWriteFlusherClosed = io.EOF
func (wf *WriteFlusher) Write(b []byte) (n int, err error) {
select {
case <-wf.closed:
return 0, errWriteFlusherClosed
return 0, io.EOF
default:
}
@@ -73,7 +71,7 @@ func (wf *WriteFlusher) Close() error {
select {
case <-wf.closed:
return errWriteFlusherClosed
return io.EOF
default:
close(wf.closed)
}