Inumedia / SlackAPI

.NET Implementation of the Slack team communication platform API.
MIT License
452 stars 243 forks source link

Fixed JSON not parsing DateTime correctly #9

Closed Denwey closed 9 years ago

Denwey commented 9 years ago

The double.Parse() method parses strings according to the current system's culture, so parsing varies between many different devices. Some cultures can lead to wrong parsing, such as disregard of the decimal point. This can lead to connection problems, such as when JSON data for LoginResponse is being deserialized, the DateTime class throws an OverflowException, which gets swallowed by the HTTP request callbacks used to fetch the response data for some reason, causing the connection to appear to fail on some cultures.

Inumedia commented 9 years ago

LGTM