Skip to content

Commit

Permalink
fixup
Browse files Browse the repository at this point in the history
  • Loading branch information
nonsense committed Sep 21, 2021
1 parent 2a69863 commit f5cb358
Showing 1 changed file with 2 additions and 13 deletions.
15 changes: 2 additions & 13 deletions cmd/lotus-miner/dagstore.go
Original file line number Diff line number Diff line change
Expand Up @@ -295,23 +295,12 @@ var dagstoreInvertedIndexSizeCmd = &cli.Command{

ctx := lcli.ReqContext(cctx)

collected, err := marketsApi.DagstoreGC(ctx)
size, err := marketsApi.DagstoreInvertedIndexSize(ctx)
if err != nil {
return err
}

if len(collected) == 0 {
_, _ = fmt.Fprintln(os.Stdout, "no shards collected")
return nil
}

for _, e := range collected {
if e.Error == "" {
_, _ = fmt.Fprintln(os.Stdout, e.Key, color.New(color.FgGreen).Sprint("SUCCESS"))
} else {
_, _ = fmt.Fprintln(os.Stdout, e.Key, color.New(color.FgRed).Sprint("ERROR"), e.Error)
}
}
fmt.Println(size)

return nil
},
Expand Down

0 comments on commit f5cb358

Please sign in to comment.