public void UpdateFromApi(TwitterDataModel.RateLimitStatus limit) { if (limit == null) { throw new ArgumentNullException(); } this.AccessLimit = new ApiLimit(limit.HourlyLimit, limit.RemainingHits, MyCommon.DateTimeParse(limit.ResetTime)); var mediaLimit = limit.Photos; if (mediaLimit != null) { this.MediaUploadLimit = new ApiLimit(mediaLimit.DailyLimit, mediaLimit.RemainingHits, MyCommon.DateTimeParse(mediaLimit.ResetTime)); } }