Allow for parsing currency without a currency sign in front

This commit is contained in:
Thomas Bloor 2018-03-21 17:24:55 +00:00
parent 2b5bb9cd8c
commit 2286e54104
No known key found for this signature in database
GPG Key ID: 4657C7EBE42CC5CC
1 changed files with 2 additions and 0 deletions

View File

@ -9,6 +9,8 @@ sub register {
my $value;
if ( $currency_string =~ /^£([\d.]+)/ ) {
$value = $1 * 1;
} elsif ( $currency_string =~ /^([\d.]+)/ ) {
$value = $1 * 1;
}
return $value;
});