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

Function methodOp

static/mergely/lib/codemirror.js:3190–3197  ·  view source on GitHub ↗
(f)

Source from the content-addressed store, hash-verified

3188 // Used to add methods to editor and doc instances, wrapping them in
3189 // operations.
3190 function methodOp(f) {
3191 return function() {
3192 if (this.curOp) return f.apply(this, arguments);
3193 startOperation(this);
3194 try { return f.apply(this, arguments); }
3195 finally { endOperation(this); }
3196 };
3197 }
3198 function docMethodOp(f) {
3199 return function() {
3200 var cm = this.cm;

Callers 1

codemirror.jsFile · 0.70

Calls 2

startOperationFunction · 0.70
endOperationFunction · 0.70

Tested by

no test coverage detected