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

Pizza cost is rounded off #1

Closed
aiden2480 opened this issue Nov 5, 2021 · 1 comment
Closed

Pizza cost is rounded off #1

aiden2480 opened this issue Nov 5, 2021 · 1 comment

Comments

@aiden2480
Copy link
Owner

aiden2480 commented Nov 5, 2021

The cost of the order is being rounded off, ignoring when the pineapple and olives options are selected because they cost less than a dollar.

The error has been isolated to commits f712325, 6710256, & 884734e, though it was discovered in commit 0fa7dc3.
It arose when I changed the datatype of the monetary variables from Decimal to Integer.

Example: The topping pineapple does not affect the pizza cost as it is only 15c and is rounded down to zero. Similar errors occur with all toppings whose price is not a whole dollar.
image
image

@aiden2480
Copy link
Owner Author

All instances of Integer was replaced with Double. The changes were tested, and performed as expected.

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

No branches or pull requests

1 participant