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

Community - Fix wallet page so that transfer history is not corrupted #38

Merged
merged 1 commit into from
Apr 30, 2019

Conversation

roadscape
Copy link
Contributor

From @eonwarped #32 and steemit/condenser#3061:

This should resolve steemit/condenser#2970 steemit/condenser#2968 steemit/condenser#2967.

The problem is that mergeDeep when given two parallel lists will merge each entry by index, and this causes some weird behavior when the two transfer history lists aren't exactly matching up. Instead, the transfer history should be replacing the old transfer history. This change attempts to do just that.

One problem is that I was unable to reproduce the linked errors predictably, so I will try to see if there's a sequence that can reproduce. For now, just wanted to show the proposed fix.

I believe this should only happen in RECEIVE_STATE, and not in the other pieces of code that merge accounts (since they are used on account fetch calls that do not contain transfer history).

Copy link
Contributor

@JonathanPorta JonathanPorta left a comment

Choose a reason for hiding this comment

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

I'd like to see the logic broken up a little bit to make it more clear and easier to read. But, at least it's tested. :)

@JonathanPorta
Copy link
Contributor

Thanks for making this better! 🥇

@roadscape roadscape merged commit ec3a446 into master Apr 30, 2019
@roadscape roadscape deleted the eonwarped-eonwarped_fixwallet branch April 30, 2019 16:39
@roadscape
Copy link
Contributor Author

Thanks @eonwarped!

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.

Duplicate transactions in the wallet page
3 participants