MCPcopy Create free account
hub / github.com/TruthHun/BookStack / methodOp

Function methodOp

static/editor.md/lib/codemirror/lib/codemirror.js:3081–3088  ·  view source on GitHub ↗
(f)

Source from the content-addressed store, hash-verified

3079 // Used to add methods to editor and doc instances, wrapping them in
3080 // operations.
3081 function methodOp(f) {
3082 return function() {
3083 if (this.curOp) return f.apply(this, arguments);
3084 startOperation(this);
3085 try { return f.apply(this, arguments); }
3086 finally { endOperation(this); }
3087 };
3088 }
3089 function docMethodOp(f) {
3090 return function() {
3091 var cm = this.cm;

Callers 1

codemirror.jsFile · 0.70

Calls 2

startOperationFunction · 0.70
endOperationFunction · 0.70

Tested by

no test coverage detected