MCPcopy Create free account
hub / github.com/Automattic/mongoose / throwErrorIfPromise

Function throwErrorIfPromise

lib/document.js:4593–4597  ·  view source on GitHub ↗
(path, transformedValue)

Source from the content-addressed store, hash-verified

4591}
4592
4593function throwErrorIfPromise(path, transformedValue) {
4594 if (isPromise(transformedValue)) {
4595 throw new Error('`transform` function must be synchronous, but the transform on path `' + path + '` returned a promise.');
4596 }
4597}
4598
4599/*!
4600 * ignore

Callers 1

Calls 1

isPromiseFunction · 0.85

Tested by

no test coverage detected