Skip to content

Commit

Permalink
Minor changes based on feedback
Browse files Browse the repository at this point in the history
  • Loading branch information
Red-Folder committed Aug 28, 2015
1 parent 1d695f1 commit 07d6a8a
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
2 changes: 1 addition & 1 deletion Octokit/Http/ApiInfo.cs
Original file line number Diff line number Diff line change
Expand Up @@ -60,7 +60,7 @@ public ApiInfo Clone()
{
// Seem to have to do this to pass a whole bunch of tests (for example Octokit.Tests.Clients.EventsClientTests.DeserializesCommitCommentEventCorrectly)
// I believe this has something to do with the Mocking framework.
if (this == null || this.Links == null || this.OauthScopes == null || this.RateLimit == null || this.Etag == null)
if (this.Links == null || this.OauthScopes == null || this.RateLimit == null || this.Etag == null)
return null;

return new ApiInfo(this.Links.Clone(),
Expand Down
12 changes: 6 additions & 6 deletions Octokit/Http/RateLimit.cs
Original file line number Diff line number Diff line change
Expand Up @@ -105,12 +105,12 @@ internal string DebuggerDisplay
/// <returns>A clone of <seealso cref="RateLimit"/></returns>
public RateLimit Clone()
{
var clone = new RateLimit();
clone.Limit = this.Limit;
clone.Remaining = this.Remaining;
clone.ResetAsUtcEpochSeconds = this.ResetAsUtcEpochSeconds;

return clone;
return new RateLimit
{
Limit = this.Limit,
Remaining = this.Remaining,
ResetAsUtcEpochSeconds = this.ResetAsUtcEpochSeconds
};
}

}
Expand Down

0 comments on commit 07d6a8a

Please sign in to comment.