UNPKG

@metamask/snaps-simulation

Version:

A simulation framework for MetaMask Snaps, enabling headless testing of Snaps in a controlled environment

21 lines 811 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); exports.getSwitchEthereumChainHandler = void 0; /** * A mock handler for the `wallet_switchEthereumChain` method that always * returns `null`. * * @param _request - Incoming JSON-RPC request. This is ignored for this * specific handler. * @param response - The outgoing JSON-RPC response, modified to return the * result. * @param _next - The `json-rpc-engine` middleware next handler. * @param end - The `json-rpc-engine` middleware end handler. * @returns The response. */ async function getSwitchEthereumChainHandler(_request, response, _next, end) { response.result = null; return end(); } exports.getSwitchEthereumChainHandler = getSwitchEthereumChainHandler; //# sourceMappingURL=switch-ethereum-chain.cjs.map