www

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

commit 207af37ee7ce4bafe40c63128b1ec53441a7a0e4
parent 3e97b803cdc7c2d74b1dd4be1974c509c8bd0cb4
Author: Dan Stillman <dstillman@zotero.org>
Date:   Fri, 26 Aug 2011 20:45:27 +0000

Don't strip extended characters in duplicate detection


Diffstat:
Mchrome/content/zotero/xpcom/duplicates.js | 3++-
1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/chrome/content/zotero/xpcom/duplicates.js b/chrome/content/zotero/xpcom/duplicates.js @@ -111,7 +111,7 @@ Zotero.Duplicates.prototype._findDuplicates = function () { str = str + ""; str = Zotero.Utilities.removeDiacritics(str) - .replace(/[^!-~]/g, ' ') // Convert punctuation to spaces + .replace(/[!-/:-@[-`{-~]/g, ' ') // Convert (ASCII) punctuation to spaces .replace(/ +/, ' ') // Normalize spaces .toLowerCase(); @@ -173,6 +173,7 @@ Zotero.Duplicates.prototype._findDuplicates = function () { processRows(function (a, b) { a = normalizeString(a.value); b = normalizeString(b.value); + // If we stripped one of the strings completely, we can't compare them if (a.length == 0 || b.length == 0) { return -1;