Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

refactor: Imporve signer confirm tx #2970

Merged
merged 13 commits into from
Jan 10, 2024
Prev Previous commit
Next Next commit
Return resp instead of nil.
  • Loading branch information
htiennv committed Jan 9, 2024
commit 0ee0973b45ca0e06b4144244a12b235608f83ee3
3 changes: 2 additions & 1 deletion pkg/user/signer.go
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,8 @@ func (s *Signer) SubmitPayForBlob(ctx context.Context, blobs []*blob.Blob, opts
return nil, err
}
if resp.Code != 0 {
return nil, fmt.Errorf("tx failed with code %d: %s", resp.Code, resp.RawLog)
// TODO(htienv): Should return nil here?
return resp, fmt.Errorf("tx failed with code %d: %s", resp.Code, resp.RawLog)
}

return s.ConfirmTx(ctx, resp.TxHash)
Expand Down