Compare commits
2 commits
Author | SHA1 | Date | |
---|---|---|---|
|
03b616622e | ||
|
50e1da01fe |
2 changed files with 3 additions and 3 deletions
|
@ -133,7 +133,7 @@ func cliMountpointInfo(requestedPath string) int {
|
||||||
|
|
||||||
fmt.Println("Path:", usage.Path)
|
fmt.Println("Path:", usage.Path)
|
||||||
fmt.Println("FS type:", ternary(usage.Fstype == "", "unknown", usage.Fstype))
|
fmt.Println("FS type:", ternary(usage.Fstype == "", "unknown", usage.Fstype))
|
||||||
fmt.Printf("Used percent: %.1f%%", usage.UsedPercent)
|
fmt.Printf("Used percent: %.1f%%\n", usage.UsedPercent)
|
||||||
|
|
||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
|
|
|
@ -182,8 +182,8 @@ func workerPoolDo[I any, O any](job *workerPoolJob[I, O]) ([]O, []error, error)
|
||||||
}
|
}
|
||||||
|
|
||||||
if len(job.data) == 1 {
|
if len(job.data) == 1 {
|
||||||
output, err := job.task(job.data[0])
|
results[0], errs[0] = job.task(job.data[0])
|
||||||
return append(results, output), append(errs, err), nil
|
return results, errs, nil
|
||||||
}
|
}
|
||||||
|
|
||||||
tasksQueue := make(chan *workerPoolTask[I, O])
|
tasksQueue := make(chan *workerPoolTask[I, O])
|
||||||
|
|
Loading…
Add table
Reference in a new issue