This repository was archived by the owner on Sep 8, 2020. It is now read-only.
Not correctly handling negative numbers larger than a couple of digits.#40
Open
aaronsaderholm wants to merge 1 commit intoasgrim:masterfrom
Open
Not correctly handling negative numbers larger than a couple of digits.#40aaronsaderholm wants to merge 1 commit intoasgrim:masterfrom
aaronsaderholm wants to merge 1 commit intoasgrim:masterfrom
Conversation
asgrim
suggested changes
Feb 21, 2017
Owner
asgrim
left a comment
There was a problem hiding this comment.
This change does not take into account existing number conversions, and breaks BC (you can tell; the tests fail). This change is in the same vein as #33 which is also a BC break; we can't fix without bumping major. Regardless of that, I can't accept this patch without accompanying tests.
| ['', '.$1'], | ||
| $amountString | ||
| ); | ||
| return floatval($amountString); |
Author
|
Thanks for the feedback, I will review. I suspect #33 fixed this problem (but with the proper tests) but I will try to evaluate that. |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to subscribe to this conversation on GitHub.
Already have an account?
Sign in.
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
I was running into an issue with this truncating negative numbers (negative account balances, so like credit cards, ect) which seemed to be fixed with this.