diff --git a/chrome/chromeFiles/content/scholar/xpcom/data_access.js b/chrome/chromeFiles/content/scholar/xpcom/data_access.js index e2543f58e..9e80bf1be 100644 --- a/chrome/chromeFiles/content/scholar/xpcom/data_access.js +++ b/chrome/chromeFiles/content/scholar/xpcom/data_access.js @@ -204,11 +204,12 @@ Scholar.Item.prototype.setCreator = function(orderIndex, firstName, lastName, cr lastName = ''; } + // If creator at this position hasn't changed, cancel if (this._creators.has(orderIndex) && this._creators.get(orderIndex)['firstName']==firstName && this._creators.get(orderIndex)['lastName']==lastName && this._creators.get(orderIndex)['creatorTypeID']==creatorTypeID){ - return true; + return false; } if (!creatorTypeID){ @@ -250,6 +251,23 @@ Scholar.Item.prototype.removeCreator = function(orderIndex){ } +Scholar.Item.prototype.creatorExists = function(firstName, lastName, creatorTypeID, skipIndex){ + for (var j=0, len=this.numCreators(); j