Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update to native OkHttp 2.0 APIs. #691

Merged
merged 1 commit into from Dec 31, 2014
Merged

Update to native OkHttp 2.0 APIs. #691

merged 1 commit into from Dec 31, 2014

Conversation

JakeWharton
Copy link
Member


public OkClient() {
this(generateDefaultOkHttp());
}

public OkClient(OkHttpClient client) {
this.okUrlFactory = new OkUrlFactory(client);
if (client == null) throw new NullPointerException("client");
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

off topic: I've been writing this as "client == null". I think this conveys just as much information in fewer characters, so by Shipley's law I should switch over. The drawback is that "client == null" is a boolean expression, and is consistent with "limit < 0" etc. . .

@swankjesse
Copy link
Member

Luke's Gotta Tiny Master

JakeWharton added a commit that referenced this pull request Dec 31, 2014
Update to native OkHttp 2.0 APIs.
@JakeWharton JakeWharton merged commit 90c363e into master Dec 31, 2014
@JakeWharton JakeWharton deleted the jw/okhttp-two branch December 31, 2014 06:29
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants