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

fix: balance returning null after second statement #6

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

OJailson17
Copy link

In the first statement, the function is returning the correct value, but after the second statement, the balance is returning null. So, when making a withdraw, the use case can't check if amount is grater than balance, and is making the withdraw even if balance is lower than the amount.

I just forced the operation amount value to be a number during reduce calculation.

@OJailson17 OJailson17 changed the title fix: getUserBalance returning null after second statement fix: balance returning null after second statement Jun 6, 2022
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.

1 participant