Skip to content

Commit

Permalink
add missing return early statement (#685)
Browse files Browse the repository at this point in the history
  • Loading branch information
Cameron Mace authored Dec 8, 2017
1 parent d63e71d commit 98c842b
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -159,6 +159,7 @@ public void onResponse(Call<DirectionsResponse> call, Response<DirectionsRespons
} else if (response.body() == null || response.body().routes().isEmpty()) {
// If null just pass the original object back since there's nothing to modify.
callback.onResponse(call, response);
return;
}
DirectionsResponse newResponse = response.body().toBuilder().routes(
generateRouteOptions(response)).build();
Expand Down

0 comments on commit 98c842b

Please sign in to comment.