Revision 316634613639 () - Diff

Link to this snippet: https://friendpaste.com/4mx38Ik7kHFzmeGiv5EMmn
Embed:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
Index: share/www/script/jquery.couch.js
===================================================================
--- share/www/script/jquery.couch.js (revision 825472)
+++ share/www/script/jquery.couch.js (working copy)
@@ -189,7 +189,9 @@
var method = "PUT";
var uri = this.uri + encodeDocId(doc._id);
}
+ if (options.async === undefined) options.async = true;
$.ajax({
+ async: options.async,
type: method, url: uri + encodeOptions(options),
contentType: "application/json",
dataType: "json", data: toJSON(doc),
@@ -362,7 +364,7 @@
var buf = [];
if (typeof(options) === "object" && options !== null) {
for (var name in options) {
- if ($.inArray(name, ["error", "success"]) >= 0)
+ if ($.inArray(name, ["error", "success", "async"]) >= 0)
continue;
var value = options[name];
if ($.inArray(name, ["key", "startkey", "endkey"]) >= 0) {