decimal not Decimal in getcurrency, fix assignment in if condition