Skip to content

Commit e7c7993

Browse files
asolovayAndroid (Google) Code Review
authored andcommitted
Merge "docs: Fixed error in code sample." into klp-modular-docs
2 parents 2a866f0 + 48ec667 commit e7c7993

1 file changed

Lines changed: 3 additions & 4 deletions

File tree

docs/html/training/location/retrieve-current.jd

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -167,13 +167,12 @@ public class MainActivity extends FragmentActivity {
167167
"Google Play services is available.");
168168
// Continue
169169
return true;
170-
// Google Play services was not available for some reason
170+
// Google Play services was not available for some reason.
171+
// resultCode holds the error code.
171172
} else {
172-
// Get the error code
173-
int errorCode = connectionResult.getErrorCode();
174173
// Get the error dialog from Google Play services
175174
Dialog errorDialog = GooglePlayServicesUtil.getErrorDialog(
176-
errorCode,
175+
resultCode,
177176
this,
178177
CONNECTION_FAILURE_RESOLUTION_REQUEST);
179178

0 commit comments

Comments
 (0)