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

Fix String.Format to handle formatting of multiple types correctly, not only DateTime #31

Merged
merged 3 commits into from
Apr 23, 2021

Commits on Apr 22, 2021

  1. Fix some unit tests not passing due to the ambient culture

    Damien Braillard committed Apr 22, 2021
    Configuration menu
    Copy the full SHA
    2dcb47c View commit details
    Browse the repository at this point in the history
  2. Fix "String.Format" helper to handle generic formatting

    "String.Format" used to only support "DateTime" for formatting.
    
    As for now, as soon as the value implements "IFormattable" that interface is used to perform the formatting. Also, if the format provider exposes a "ICustomFormatter" service, that formatter is used first for formatting the value.
    
    The formatting falls back to "ToString()" or to an empty string if the value to format is null.
    Damien Braillard committed Apr 22, 2021
    Configuration menu
    Copy the full SHA
    c06330c View commit details
    Browse the repository at this point in the history

Commits on Apr 23, 2021

  1. Replaced "" by string.Empty to adhere to coding standards

    Damien Braillard committed Apr 23, 2021
    Configuration menu
    Copy the full SHA
    658b0e7 View commit details
    Browse the repository at this point in the history