diff options
| author | Randall Leeds <randall@apache.org> | 2012-01-16 22:01:40 -0800 |
|---|---|---|
| committer | Randall Leeds <randall@apache.org> | 2012-01-26 17:02:41 -0800 |
| commit | 0c619ed996390f6de24f87ce6f2c380295e152aa (patch) | |
| tree | 38853880fe1181484b0a130c99ec068959c70bcb /share/server/loop.js | |
| parent | 32a1113417c25deee9052e7d3de37cc0faea9914 (diff) | |
| download | couchdb-0c619ed996390f6de24f87ce6f2c380295e152aa.tar.gz | |
COUCHDB-111 CommonJS module names in tracebacks
Adds an optional third argument to the `evalcx` function in the JS view
server to pass a filename for display in stacktraces for `Error`
objects. Updates the CommonJS support to use this when `require`ing
modules.
Diffstat (limited to 'share/server/loop.js')
| -rw-r--r-- | share/server/loop.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/share/server/loop.js b/share/server/loop.js index 986c8b3f8..fcd016f17 100644 --- a/share/server/loop.js +++ b/share/server/loop.js @@ -98,7 +98,7 @@ var DDoc = (function() { " on design doc " + ddocId]); } if (typeof fun != "function") { - fun = Couch.compileFunction(fun, ddoc); + fun = Couch.compileFunction(fun, ddoc, funPath.join('.')); // cache the compiled fun on the ddoc point[funPath[i]] = fun; }; |
