commit 56eb416e3ee058594c1dec056cb408241650e04b
parent 7a2d7594d4cd39ca9ac44452f3799c9b844e4637
Author: Dan Stillman <dstillman@zotero.org>
Date: Fri, 24 Oct 2008 21:08:44 +0000
Fix error in doc prefs window if lastStyle is set to an invalid style
Diffstat:
1 file changed, 2 insertions(+), 1 deletion(-)
diff --git a/chrome/content/zotero/bibliography.js b/chrome/content/zotero/bibliography.js
@@ -62,6 +62,7 @@ var Zotero_File_Interface_Bibliography = new function() {
// add styles to list
var index = 0;
var nStyles = styles.length;
+ var selectIndex = -1;
for(var i=0; i<nStyles; i++) {
var itemNode = document.createElement("listitem");
itemNode.setAttribute("value", styles[i].styleID);
@@ -69,7 +70,7 @@ var Zotero_File_Interface_Bibliography = new function() {
listbox.appendChild(itemNode);
if(styles[i].styleID == _io.style) {
- var selectIndex = index;
+ selectIndex = index;
}
index++;
}