chrome/renderer/resources/extension_process_bindings.js
// Send an API request and optionally register a callback.
Send an API request and optionally register a callback.
Send an API request and optionally register a callback .
function sendRequest(request, args, callback) {
    if (args === undefined)
      args = null;
    var sargs = JSON.stringify(args);
    var requestId = GetNextRequestId();
    var hasCallback = false;
    if (callback) {
      hasCallback = true;
      callbacks[requestId] = callback;
    }
    request(sargs, requestId, hasCallback);
  }
function sendRequest ( request , args , callback ) { if ( args === undefined ) args = null ; var sargs = JSON . stringify ( args ) ; var requestId = GetNextRequestId ( ) ; var hasCallback = false ; if ( callback ) { hasCallback = true ; callbacks [ requestId ] = callback ; } request ( sargs , requestId , hasCallback ) ; }
Send an API request and optionally register a callback.
Send an API request and optionally register a callback .
// JSON.stringify doesn't support a root object which is undefined.