Skip to content

Support for lowercase currency #74

@that-guy-iain

Description

@that-guy-iain

There are some APIs that return the currency code in a lowercase. This results in an unknown currency code and a whole bunch of strtoupper calls all over the codebase it makes the code fundamentally fragile if a strtoupper is missed somewhere the code ends up breaking somewhere.

I purpose that Currency::of supports upper and lower case. It would be a lot easier to add a strtoupper there to ensure all codes passed at converted to upper case. Thus isolating this logic that the currency code must be uppercase.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions