Skip to content

fixes regex to determine percentage and parse decimal value

Latest
Compare
Choose a tag to compare
@pmcalmeida pmcalmeida released this 01 Aug 11:42

The current regex to determine if it is a valid percentage between 0 and 100 was wrong since it was only matching the 0 or 1 characters, it was replaced with a proper regex.
Also calculate decima value was removing the last digit of the value, so now it is only removing the percentage character and dividing the value by 100