(db, fun, doc)
| 8144 | function createAbstractMapReduce(localDocName, mapper, reducer, ddocValidator) { |
| 8145 | |
| 8146 | function tryMap(db, fun, doc) { |
| 8147 | // emit an event if there was an error thrown by a map function. |
| 8148 | // putting try/catches in a single function also avoids deoptimizations. |
| 8149 | try { |
| 8150 | fun(doc); |
| 8151 | } catch (e) { |
| 8152 | emitError(db, e, {fun, doc}); |
| 8153 | } |
| 8154 | } |
| 8155 | |
| 8156 | function tryReduce(db, fun, keys, values, rereduce) { |
| 8157 | // same as above, but returning the result or an error. there are two separate |
no test coverage detected
searching dependent graphs…