You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cordova.apache.org by GitBox <gi...@apache.org> on 2020/01/02 14:40:13 UTC

[GitHub] [cordova-plugin-inappbrowser] timbru31 commented on a change in pull request #503: (android) Defensive code to prevent NULL reference exceptions for async

timbru31 commented on a change in pull request #503: (android) Defensive code to prevent NULL reference exceptions for async
URL: https://github.com/apache/cordova-plugin-inappbrowser/pull/503#discussion_r362495008
 
 

 ##########
 File path: src/android/InAppBrowser.java
 ##########
 @@ -1066,12 +1070,16 @@ public void postMessage(String data) {
                 lp.height = WindowManager.LayoutParams.MATCH_PARENT;
 
                 dialog.setContentView(main);
-                dialog.show();
+                if(dialog != null){
 
 Review comment:
   And add a space after the `if` and before the `{` for all new guards 🙃

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
users@infra.apache.org


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: commits-unsubscribe@cordova.apache.org
For additional commands, e-mail: commits-help@cordova.apache.org