www

Unnamed repository; edit this file 'description' to name the repository.
Log | Files | Refs | Submodules | README | LICENSE

commit 9e8d822b9045bdc788ac953400860939797669c1
parent c942afb2b0ca30bea39eec1e04a366ea142b255c
Author: Dan Stillman <dstillman@zotero.org>
Date:   Thu, 20 Nov 2008 21:29:54 +0000

Fix another problem with Sakai's href attribute handling


Diffstat:
Mchrome/content/zotero/xpcom/storage.js | 14++++++++------
1 file changed, 8 insertions(+), 6 deletions(-)

diff --git a/chrome/content/zotero/xpcom/storage.js b/chrome/content/zotero/xpcom/storage.js @@ -868,17 +868,19 @@ Zotero.Sync.Storage = new function () { href = href.path; } - if (href.indexOf(path) == -1) { + if (href.indexOf(path) == -1 + // Try URL-encoded as well, in case there's a '~' or similar + // character in the URL and the server (e.g., Sakai) is + // encoding the value + && decodeURIComponent(href).indexOf(path) == -1) { _error("DAV:href '" + href + "' does not begin with path '" + path + "' in " + funcName); } // Skip root URI - // - // Try URL-encoded as well, in case there's a '~' or similar - // character in the URL and the server (e.g., Sakai) is - // encoding the value - if (href == path || decodeURIComponent(href) == path) { + if (href == path + // Try URL-encoded as well, as above + || decodeURIComponent(href) == path) { continue; }