diff --git a/progress.go b/progress.go index 449fbdd..448574c 100644 --- a/progress.go +++ b/progress.go @@ -26,7 +26,7 @@ uwg *sync.WaitGroup bwg *sync.WaitGroup operateState chan func(*pState) - interceptIo chan func(io.Writer) + interceptIO chan func(io.Writer) done chan struct{} shutdown chan struct{} cancel func() @@ -87,7 +87,7 @@ uwg: s.uwg, bwg: new(sync.WaitGroup), operateState: make(chan func(*pState)), - interceptIo: make(chan func(io.Writer)), + interceptIO: make(chan func(io.Writer)), done: make(chan struct{}), shutdown: make(chan struct{}), cancel: cancel, @@ -183,7 +183,7 @@ } ch := make(chan *result) select { - case p.interceptIo <- func(w io.Writer) { + case p.interceptIO <- func(w io.Writer) { n, err := w.Write(b) ch <- &result{n, err} }: @@ -254,7 +254,7 @@ select { case op := <-p.operateState: op(s) - case fn := <-p.interceptIo: + case fn := <-p.interceptIO: fn(cw) case <-tickerC: e := render()