diff options
author | John Christopher Anderson <jchris@apache.org> | 2009-06-14 18:45:49 +0000 |
---|---|---|
committer | John Christopher Anderson <jchris@apache.org> | 2009-06-14 18:45:49 +0000 |
commit | cd39ebe7d12d999324ff2cc9842567b34dc4d4c7 (patch) | |
tree | 00bde7d855ba9cd07c2e5d0463dfd32c4f0badcc /share/server/util.js | |
parent | 88fcbd2cdd14fedab900fbf3af3deb5fe15f4390 (diff) |
merge list-iterator branch to trunk. changes JavaScript _list API
git-svn-id: https://svn.apache.org/repos/asf/couchdb/trunk@784601 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'share/server/util.js')
-rw-r--r-- | share/server/util.js | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/share/server/util.js b/share/server/util.js index 7faf2f0b..13b8a779 100644 --- a/share/server/util.js +++ b/share/server/util.js @@ -91,10 +91,8 @@ function recursivelySeal(obj) { } } -var responseSent; // prints the object as JSON, and rescues and logs any toJSON() related errors function respond(obj) { - responseSent = true; try { print(toJSON(obj)); } catch(e) { @@ -103,10 +101,11 @@ function respond(obj) { }; log = function(message) { + // return; if (typeof message == "undefined") { message = "Error: attempting to log message of 'undefined'."; } else if (typeof message != "string") { message = toJSON(message); } - print(toJSON({log: message})); + respond(["log", message]); }; |