Mathieu N created CB-12184:
------------------------------

             Summary: executeScript leads to a null pointer on exception on 
Android.
                 Key: CB-12184
                 URL: https://issues.apache.org/jira/browse/CB-12184
             Project: Apache Cordova
          Issue Type: Bug
          Components: Plugin InAppBrowser
         Environment: Android 6.0 / OnePlus One / Ionic2 (rc2)
            Reporter: Mathieu N


Hi,

I am using the following typescript code:

{code:javascript}
let browser = new InAppBrowser('https://some_url', '_system');

let script:string = "someJs";
                        
browser.executeScript({code: script});
{code}

Upon execution, it yields the following stacktrace:

{panel}
java.lang.NullPointerException: Attempt to invoke virtual method 'void 
android.webkit.WebView.evaluateJavascript(java.lang.String, 
android.webkit.ValueCallback)' on a null object reference
        at 
org.apache.cordova.inappbrowser.InAppBrowser$3.run(InAppBrowser.java:333)
        at android.os.Handler.handleCallback(Handler.java:739)
        at android.os.Handler.dispatchMessage(Handler.java:95)
        at android.os.Looper.loop(Looper.java:148)
        at android.app.ActivityThread.main(ActivityThread.java:5461)
        at java.lang.reflect.Method.invoke(Native Method)
        at 
com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:726)
        at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:616)
{panel}

M.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to