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

Add verifreg balance to datacap #110

Merged
merged 2 commits into from
Oct 21, 2022
Merged

Conversation

ZenGround0
Copy link
Contributor

This refactors full proposal traversal to a single preliminary call that collects deal IDs of verified pending deals for verifreg migration and their total size for datacap migration

* refactor proposal traversal to outside of migrations for efficiency
return nil
for _, dealID := range pendingDeals {
proposal, err := proposals.GetDealProposal(dealID)
if err != nil || proposal == nil {
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

proposal == nil should not be reachable but I figured an explicit error is minutely nicer than a panic

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Agreed

@ZenGround0 ZenGround0 merged commit 67cc2b3 into master Oct 21, 2022
@ZenGround0 ZenGround0 deleted the fix/track-verifreg-datacap branch October 21, 2022 21:03
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants