We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
range
1 parent bbebeab commit d29346aCopy full SHA for d29346a
progress.go
@@ -10,16 +10,10 @@
10
// go func() {
11
// ctx := context.Background()
12
// progressChan := progress.NewTicker(ctx, r, size, 1*time.Second)
13
-// for {
14
-// select {
15
-// case progress, ok := <-progressChan:
16
-// if !ok {
17
-// fmt.Println("\rdownload is completed")
18
-// return
19
-// }
20
-// fmt.Printf("\r%v remaining...", progress.Remaining().Round(time.Second))
21
+// for p := range progressChan {
+// fmt.Printf("\r%v remaining...", p.Remaining().Round(time.Second))
22
// }
+// fmt.Println("\rdownload is completed")
23
// }()
24
//
25
// // use the Reader as normal
0 commit comments