Skip to content
This repository was archived by the owner on May 30, 2023. It is now read-only.

Commit d4daad7

Browse files
#270 Crash - GooglePlus.java - nl.xservices.plugins.GooglePlus.handleSignInResult
1 parent c5070e7 commit d4daad7

File tree

1 file changed

+7
-2
lines changed

1 file changed

+7
-2
lines changed

Diff for: src/android/GooglePlus.java

+7-2
Original file line numberDiff line numberDiff line change
@@ -275,7 +275,12 @@ private void handleSignInResult(GoogleSignInResult signInResult) {
275275
savedCallbackContext.error("GoogleApiClient was never initialized");
276276
return;
277277
}
278-
278+
279+
if (signInResult == null) {
280+
savedCallbackContext.error("SignInResult is null");
281+
return;
282+
}
283+
279284
Log.i(TAG, "Handling SignIn Result");
280285

281286
if (!signInResult.isSuccess()) {
@@ -304,7 +309,7 @@ private void handleSignInResult(GoogleSignInResult signInResult) {
304309
result.put("familyName", acct.getFamilyName());
305310
result.put("givenName", acct.getGivenName());
306311
result.put("imageUrl", acct.getPhotoUrl());
307-
312+
308313
this.savedCallbackContext.success(result);
309314
} catch (JSONException e) {
310315
savedCallbackContext.error("Trouble parsing result, error: " + e.getMessage());

0 commit comments

Comments
 (0)