Don't throw error if there's no Zotero.Styles.lastCSL

This commit is contained in:
Dan Stillman 2008-09-15 19:54:09 +00:00
parent b7fc5e66f2
commit 1ab118c9af

View file

@ -172,7 +172,8 @@ Zotero.Style.prototype.__defineGetter__("csl",
*/
function() {
// cache last style
if(Zotero.Styles.cacheTranslatorData && Zotero.Styles.lastCSL.styleID == this.styleID) {
if(Zotero.Styles.cacheTranslatorData && Zotero.Styles.lastCSL &&
Zotero.Styles.lastCSL.styleID == this.styleID) {
return Zotero.Styles.lastCSL;
}