iOS web browser with a focus on security and privacy

injected.js: don't replace console object, just redefine functions

There are a bunch of functions that we don't implement that some
sites use, so let those fall through.

https://developer.mozilla.org/en-US/docs/Web/API/Console

+5 -8
+5 -8
Endless/Resources/injected.js
··· 286 286 }; 287 287 288 288 /* pipe back to app */ 289 - console = { 290 - _log: function(urg, args) { 291 - if (args.length == 1) 292 - args = args[0]; 293 - __endless.ipc("console.log/" + urg + "?" + 294 - encodeURIComponent(JSON.stringify(args))); 295 - }, 289 + console._log = function(urg, args) { 290 + if (args.length == 1) 291 + args = args[0]; 292 + __endless.ipc("console.log/" + urg + "?" + encodeURIComponent(JSON.stringify(args))); 296 293 }; 297 294 console.log = function() { console._log("log", arguments); }; 298 295 console.debug = function() { console._log("debug", arguments); }; 299 296 console.info = function() { console._log("info", arguments); }; 300 297 console.warn = function() { console._log("warn", arguments); }; 301 298 console.error = function() { console._log("error", arguments); }; 302 - 299 + 303 300 if (document.readyState == "complete" || document.readyState == "interactive") 304 301 __endless.onLoad(); 305 302 else