Improved logging

pull/198/head
M66B 4 years ago
parent 3c2b4c6f70
commit 22c283f351

@ -218,7 +218,7 @@ public class FragmentGmail extends FragmentBase {
if (resultCode == RESULT_OK && data != null)
onAccountSelected(data);
else
onNoAccountSelected();
onNoAccountSelected(resultCode, data);
break;
case ActivitySetup.REQUEST_DONE:
finish();
@ -258,11 +258,11 @@ public class FragmentGmail extends FragmentBase {
});
}
private void onNoAccountSelected() {
private void onNoAccountSelected(int resultCode, Intent data) {
AccountManager am = AccountManager.get(getContext());
Account[] accounts = am.getAccountsByType(TYPE_GOOGLE);
if (accounts.length == 0) {
Log.e("newChooseAccountIntent without result");
Log.e("newChooseAccountIntent without result=" + resultCode + " data=" + data);
ToastEx.makeText(getContext(), R.string.title_no_account, Toast.LENGTH_LONG).show();
}
}

Loading…
Cancel
Save