MCPcopy Create free account
hub / github.com/porsager/postgres / savepoint

Function savepoint

cjs/src/index.js:283–289  ·  view source on GitHub ↗
(name, fn)

Source from the content-addressed store, hash-verified

281 return result
282
283 function savepoint(name, fn) {
284 if (name && Array.isArray(name.raw))
285 return savepoint(sql => sql.apply(sql, arguments))
286
287 arguments.length === 1 && (fn = name, name = null)
288 return scope(c, fn, 's' + savepoints++ + (name ? '_' + name : ''))
289 }
290
291 function handler(q) {
292 q.catch(e => uncaughtError || (uncaughtError = e))

Callers

nothing calls this directly

Calls 1

scopeFunction · 0.70

Tested by

no test coverage detected