Fix NPE in InAppBrowser's error callback.

Reprocudes using the mobile spec's test page.
[CB-2653] Simplify InAppBrowser.injectScriptCode.

The previous commit was an outdated pull request. This one is the
correct one (whoops).