Merge pull request #1219 from adomasven:fix/htmlSpecialChars
Do not return empty string only for `0` arg to #htmlSpecialChars
This commit is contained in:
commit
b077e1cd8c
1 changed files with 3 additions and 1 deletions
|
@ -459,7 +459,9 @@ Zotero.Utilities = {
|
||||||
* @return {String}
|
* @return {String}
|
||||||
*/
|
*/
|
||||||
"htmlSpecialChars":function(str) {
|
"htmlSpecialChars":function(str) {
|
||||||
if (str !== undefined && typeof str != 'string') {
|
if (str && typeof str != 'string') {
|
||||||
|
Zotero.debug('#htmlSpecialChars: non-string arguments are deprecated. Update your code',
|
||||||
|
1, undefined, true);
|
||||||
str = str.toString();
|
str = str.toString();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Reference in a new issue