Skip to content

Commit a381e13

Browse files
SUPERCILEXsamtstern
authored andcommitted
Remove deprecated references from README (#1173)
1 parent 0e5bb59 commit a381e13

File tree

1 file changed

+5
-10
lines changed

1 file changed

+5
-10
lines changed

auth/README.md

Lines changed: 5 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -340,7 +340,6 @@ protected void onActivityResult(int requestCode, int resultCode, Intent data) {
340340
if (resultCode == RESULT_OK) {
341341
startActivity(SignedInActivity.createIntent(this, response));
342342
finish();
343-
return;
344343
} else {
345344
// Sign in failed
346345
if (response == null) {
@@ -349,20 +348,16 @@ protected void onActivityResult(int requestCode, int resultCode, Intent data) {
349348
return;
350349
}
351350

352-
if (response.getErrorCode() == ErrorCodes.NO_NETWORK) {
351+
if (response.getError().getErrorCode() == ErrorCodes.NO_NETWORK) {
353352
showSnackbar(R.string.no_internet_connection);
354353
return;
355354
}
356-
357-
if (response.getErrorCode() == ErrorCodes.UNKNOWN_ERROR) {
358-
showSnackbar(R.string.unknown_error);
359-
return;
360-
}
355+
356+
showSnackbar(R.string.unknown_error);
357+
Log.e(TAG, "Sign-in error: ", response.getError());
361358
}
362-
363-
showSnackbar(R.string.unknown_sign_in_response);
364359
}
365-
}
360+
}
366361
```
367362

368363
Alternatively, you can register a listener for authentication state changes;

0 commit comments

Comments
 (0)