Permalink
Browse files

This should be an NSInteger, not an NSTimeInterval. Thanks to Rudy Ri…

…chter for bringing this to my attention.
  • Loading branch information...
1 parent f04c28b commit 35f4248b2747dee9716c9f59ccada16862a5278c Peter Hosey committed Nov 14, 2011
Showing with 2 additions and 2 deletions.
  1. +2 −2 ISO8601DateFormatter.m
View
4 ISO8601DateFormatter.m
@@ -553,8 +553,8 @@ - (NSDateComponents *) dateComponentsFromString:(NSString *)string timeZone:(out
if (negative) tz_minute = -tz_minute;
}
- NSTimeInterval timeZoneOffset = (tz_hour * 3600) + (tz_minute * 60);
- NSNumber *offsetNum = [NSNumber numberWithDouble:timeZoneOffset];
+ NSInteger timeZoneOffset = (tz_hour * 3600) + (tz_minute * 60);
+ NSNumber *offsetNum = [NSNumber numberWithInteger:timeZoneOffset];
timeZone = [timeZonesByOffset objectForKey:offsetNum];
if (!timeZone) {
timeZone = [NSTimeZone timeZoneForSecondsFromGMT:timeZoneOffset];

0 comments on commit 35f4248

Please sign in to comment.