Fix abbreviation of single word titles
https://forums.zotero.org/discussion/28687/
This commit is contained in:
parent
193b10a1f5
commit
e51434416a
1 changed files with 4 additions and 2 deletions
|
@ -429,12 +429,14 @@ Zotero.Cite.getAbbreviation = new function() {
|
||||||
}
|
}
|
||||||
|
|
||||||
// Fall back to full word
|
// Fall back to full word
|
||||||
if(newWord === undefined ) newWord = word;
|
if(newWord === undefined) newWord = word;
|
||||||
|
|
||||||
words[j] = newWord.substr(0, 1).toUpperCase() + newWord.substr(1);
|
words[j] = newWord.substr(0, 1).toUpperCase() + newWord.substr(1);
|
||||||
}
|
}
|
||||||
|
abbreviation = words.join("").replace(/\s+/g, " ").trim();
|
||||||
|
} else {
|
||||||
|
abbreviation = key;
|
||||||
}
|
}
|
||||||
abbreviation = words.join("").replace(/\s+/g, " ").trim();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
if(!abbreviation || abbreviation === key) {
|
if(!abbreviation || abbreviation === key) {
|
||||||
|
|
Loading…
Reference in a new issue