Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -260,7 +260,7 @@ public Builder enableLogging() {
* @throws IllegalStateException when the builder was not configured correctly
*/
public Guardian build() {
if (url == null) {
if (this.url == null) {
throw new IllegalStateException("You must set either a domain or an url");
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -358,7 +358,7 @@ public Builder enableLogging() {
* @throws IllegalStateException when the builder was not configured correctly
*/
public GuardianAPIClient build() {
if (url == null) {
if (this.url == null) {
throw new IllegalStateException("You must set either a domain or an url");
}

Expand Down Expand Up @@ -398,7 +398,7 @@ public Response intercept(Chain chain) throws IOException {

RequestFactory requestFactory = new RequestFactory(gson, client);

return new GuardianAPIClient(requestFactory, url);
return new GuardianAPIClient(requestFactory, this.url);
}
}
}