summaryrefslogtreecommitdiff
path: root/share/www/script/jquery.couch.js
diff options
context:
space:
mode:
authorJohn Christopher Anderson <jchris@apache.org>2010-01-18 03:45:54 +0000
committerJohn Christopher Anderson <jchris@apache.org>2010-01-18 03:45:54 +0000
commit09351a0535fe9bc3fa780763c095fd6dc56175de (patch)
treebb5940d322a8ed152c1e933c564ca51ed4ae6231 /share/www/script/jquery.couch.js
parent0a94f47f2b962048837a6a28449bfd962dd1fd3e (diff)
normalize userCtx name and roles, also, no log in via a conflict doc
git-svn-id: https://svn.apache.org/repos/asf/couchdb/trunk@900275 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'share/www/script/jquery.couch.js')
-rw-r--r--share/www/script/jquery.couch.js6
1 files changed, 3 insertions, 3 deletions
diff --git a/share/www/script/jquery.couch.js b/share/www/script/jquery.couch.js
index 7e8a0236..0203fd45 100644
--- a/share/www/script/jquery.couch.js
+++ b/share/www/script/jquery.couch.js
@@ -28,7 +28,7 @@
return;
}
var user_prefix = "org.couchdb.user:";
- user_doc._id = user_doc._id || user_prefix + user_doc.username;
+ user_doc._id = user_doc._id || user_prefix + user_doc.name;
if (new_password) {
// handle the password crypto
user_doc.salt = $.couch.newUUID();
@@ -102,7 +102,7 @@
userDb : function(callback) {
$.couch.session({
success : function(resp) {
- var userDb = $.couch.db(resp.info.user_db);
+ var userDb = $.couch.db(resp.info.authentication_db);
callback(userDb);
}
});
@@ -121,7 +121,7 @@
options = options || {};
$.ajax({
type: "POST", url: "/_session", dataType: "json",
- data: {username: options.username, password: options.password},
+ data: {name: options.name, password: options.password},
complete: function(req) {
var resp = $.httpData(req, "json");
if (req.status == 200) {