MCPcopy Index your code
hub / github.com/ClearURLs/Addon / wrapMethod

Function wrapMethod

browser-polyfill.js:877–883  ·  view source on GitHub ↗
(target, method, wrapper)

Source from the content-addressed store, hash-verified

875 * method in its place.
876 */
877 const wrapMethod = (target, method, wrapper) => {
878 return new Proxy(method, {
879 apply(targetMethod, thisObj, args) {
880 return wrapper.call(thisObj, target, ...args);
881 }
882 });
883 };
884 let hasOwnProperty = Function.call.bind(Object.prototype.hasOwnProperty);
885
886 /**

Callers 1

getFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected