tor-browser

The Tor Browser
git clone https://git.dasho.dev/tor-browser.git
Log | Files | Refs | README | LICENSE

pauseOnDebuggerStatement.js (634B)


      1 /* This Source Code Form is subject to the terms of the Mozilla Public
      2 * License, v. 2.0. If a copy of the MPL was not distributed with this
      3 * file, You can obtain one at <http://mozilla.org/MPL/2.0/>. */
      4 
      5 const {
      6  PROMISE,
      7 } = require("resource://devtools/client/shared/redux/middleware/promise.js");
      8 
      9 export function pauseOnDebuggerStatement(shouldPauseOnDebuggerStatement) {
     10  return ({ dispatch, client }) => {
     11    return dispatch({
     12      type: "PAUSE_ON_DEBUGGER_STATEMENT",
     13      shouldPauseOnDebuggerStatement,
     14      [PROMISE]: client.pauseOnDebuggerStatement(
     15        shouldPauseOnDebuggerStatement
     16      ),
     17    });
     18  };
     19 }