fix error handling

This commit is contained in:
aarshkshah1992
2021-06-04 21:41:09 +02:00
committed by Łukasz Magiera
parent 8733cea902
commit 182da9d4ef
+3 -3
View File
@@ -1204,10 +1204,10 @@ var clientRetrieveCmd = &cli.Command{
if !ok {
if evt.Status == retrievalmarket.DealStatusCompleted {
afmt.Println("Success")
return nil
} else {
afmt.Printf("saw final deal state %s instead of expected success state DealStatusCompleted", retrievalmarket.DealStatuses[evt.Status])
}
return xerrors.Errorf("saw final deal state %s instead of expected state DealStatusCompleted", retrievalmarket.DealStatuses[evt.Status])
return nil
}
case <-ctx.Done():