Skip to content

Conversation

@strmci
Copy link
Collaborator

@strmci strmci commented Dec 1, 2025

When there were only two transactions within a short period of time, the My Portfolio chart did not display. This update ensures that the chart is shown in these situations.

When there were only two transactions within a short
period of time, the My Portfolio chart did not display.
This update ensures that the chart is shown in these
situations.
@strmci strmci requested a review from Beerosagos December 1, 2025 17:41
Copy link
Contributor

@benma benma left a comment

Choose a reason for hiding this comment

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

Please add unit tests.

Comment on lines +281 to +287
allZero := true
for _, e := range result {
if e.Value.BigInt() != nil && e.Value.BigInt().Sign() != 0 {
allZero = false
break
}
}
Copy link
Contributor

Choose a reason for hiding this comment

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

@Beerosagos
Copy link
Collaborator

I'm not sure I like this solution, it seems to add another workaround to the chart code, which is already quite complicated. Maybe we should take some time to discuss a heavier refactoring of how the chart works to simplify it a bit.
Btw, in my tests this didn't completely fix the issue, as the chart didn't appear until I restarted the app, I'm not sure why.

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.

3 participants