Skip to content

Instantly share code, notes, and snippets.

Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save jzeferino/06ad8f3c7454b7bfbd123a2cfd9ce209 to your computer and use it in GitHub Desktop.
Save jzeferino/06ad8f3c7454b7bfbd123a2cfd9ce209 to your computer and use it in GitHub Desktop.
Culture invariant IUrlParameterFormatter for Refit
using System;
using System.Globalization;
using System.Reflection;
namespace Refit
{
public sealed class InvariantUrlParameterFormatter : IUrlParameterFormatter
{
public string Format(object parameterValue, ParameterInfo parameterInfo)
{
return Convert.ToString(parameterValue, CultureInfo.InvariantCulture);
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment