- Fix an XML parsing error (due to trailing whitespace, weirdly) that could cause endless sync icon spinning
- Remove extra whitespace in collection-item blocks that was causing sync upload errors (also fixed on the server)
This commit is contained in:
parent
4bc7ab9016
commit
6a629490b3
|
@ -1351,8 +1351,10 @@ Zotero.Sync.Server = new function () {
|
||||||
_error(response.firstChild.firstChild.nodeValue);
|
_error(response.firstChild.firstChild.nodeValue);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
var xml = Zotero.Utilities.prototype.trim(xmlhttp.responseText.replace(/<\?xml.*\?>\s*/, ''));
|
||||||
|
|
||||||
// Strip XML declaration and convert to E4X
|
// Strip XML declaration and convert to E4X
|
||||||
var xml = new XML(xmlhttp.responseText.replace(/<\?xml.*\?>/, ''));
|
xml = new XML(xml);
|
||||||
|
|
||||||
try {
|
try {
|
||||||
var updateKey = xml.@updateKey.toString();
|
var updateKey = xml.@updateKey.toString();
|
||||||
|
@ -3741,7 +3743,7 @@ Zotero.Sync.Server.Data = new function() {
|
||||||
xml.collections + ' ' + child.id : child.id;
|
xml.collections + ' ' + child.id : child.id;
|
||||||
}
|
}
|
||||||
else */if (child.type == 'item') {
|
else */if (child.type == 'item') {
|
||||||
xml.items = xml.items ?
|
xml.items = xml.items.toString() ?
|
||||||
xml.items + ' ' + child.key : child.key;
|
xml.items + ' ' + child.key : child.key;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue
Block a user