commit c57f512aea43abb7941d82defe2a6f8b19c839f6 parent bacd25633b34897f314a323a59d272678a371609 Author: Simon Kornblith <simon@simonster.com> Date: Sun, 5 Aug 2012 19:44:04 -0400 Don't save null tags to server Diffstat:
| M | chrome/content/zotero/xpcom/utilities.js | | | 4 | ++-- |
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/chrome/content/zotero/xpcom/utilities.js b/chrome/content/zotero/xpcom/utilities.js @@ -1218,7 +1218,7 @@ Zotero.Utilities = { } else if(field === "tags") { // normalize tags var n = val.length; - var newTags = newItem.tags = new Array(n); + var newTags = newItem.tags = []; for(var j=0; j<n; j++) { var tag = val[j]; if(typeof tag === "object") { @@ -1233,7 +1233,7 @@ Zotero.Utilities = { } else if(tag === "") { continue; } - newTags[j] = {"tag":tag.toString(), "type":1}; + newTags.push({"tag":tag.toString(), "type":1}); } } else if(field === "notes") { // normalize notes