Fixes #576, Stuck at "Loading library..."

This commit is contained in:
Dan Stillman 2007-03-23 00:40:26 +00:00
parent c25836f373
commit b7caed7e71
3 changed files with 5 additions and 2 deletions

View File

@ -574,7 +574,7 @@ Zotero.Item.prototype.setField = function(field, value, loadIn){
} }
if (!Zotero.ItemFields.isValidForType(fieldID, this.getType())){ if (!Zotero.ItemFields.isValidForType(fieldID, this.getType())){
throw ('"' + field + "' is not a valid field for this type."); throw ('"' + field + "' is not a valid field for type " + this.getType());
} }
if (!loadIn){ if (!loadIn){

View File

@ -139,6 +139,9 @@ Zotero.ItemTreeView.prototype.refresh = function()
// Cache the visible fields so they don't load individually // Cache the visible fields so they don't load individually
var visibleFields = this.getVisibleFields(); var visibleFields = this.getVisibleFields();
for each(var field in visibleFields) { for each(var field in visibleFields) {
if (field == 'year') {
field = 'date';
}
if (cacheFields.indexOf(field) == -1) { if (cacheFields.indexOf(field) == -1) {
cacheFields = cacheFields.concat(field); cacheFields = cacheFields.concat(field);
} }

View File

@ -129,7 +129,7 @@ Zotero.Report = new function() {
continue; continue;
} }
// Convert false to empty string // Skip empty fields
if (!arr[i]) { if (!arr[i]) {
continue; continue;
} }