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

trim whitespace on value_to_currency when string #352

Closed

Conversation

salimshopbou
Copy link

Encountered an issue with whitespace in the value_to_currency method here

Ideally we shouldn't have leading or trailing whitespace for currencies passed in, but this is a simple bit of string preprocessing that might help alleviate some unintended errors.

@salimshopbou salimshopbou force-pushed the salimshopbou/trim-whitespace-value-to-currency branch from 5459c4e to e9f6938 Compare December 6, 2024 16:56
@elfassy
Copy link
Contributor

elfassy commented Jan 8, 2025

the ideal solution here is to fix the data in the database. There could be other systems that look at this value and would not get this fix (ex: something that does a currency conversion). The currency is usually not something our users input into our system, so it should not be susceptible to typos. Fixing this here would make it harder to find the root of the issue. Let me know if there's something I'm missing

@elfassy elfassy closed this Jan 8, 2025
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

Successfully merging this pull request may close these issues.

2 participants