Fx60 compatibility: Update old-style shorthand function definitions
This commit is contained in:
parent
b835970ead
commit
676799271e
|
@ -1157,7 +1157,7 @@
|
||||||
|
|
||||||
if (this.eventHandlers['itemtypechange'] && this.eventHandlers['itemtypechange'].length) {
|
if (this.eventHandlers['itemtypechange'] && this.eventHandlers['itemtypechange'].length) {
|
||||||
var self = this;
|
var self = this;
|
||||||
this.eventHandlers['itemtypechange'].forEach(function (f) f.bind(self)());
|
this.eventHandlers['itemtypechange'].forEach(f => f.bind(self)());
|
||||||
}
|
}
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
|
|
@ -139,7 +139,7 @@
|
||||||
<body><![CDATA[
|
<body><![CDATA[
|
||||||
return Zotero.spawn(function* () {
|
return Zotero.spawn(function* () {
|
||||||
if (type == 'setting') {
|
if (type == 'setting') {
|
||||||
if (ids.some(function (val) val.split("/")[1] == 'tagColors') && this.item) {
|
if (ids.some(val => val.split("/")[1] == 'tagColors') && this.item) {
|
||||||
this.reload();
|
this.reload();
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
@ -227,7 +227,7 @@
|
||||||
|
|
||||||
// Sort tags alphabetically
|
// Sort tags alphabetically
|
||||||
var collation = Zotero.getLocaleCollation();
|
var collation = Zotero.getLocaleCollation();
|
||||||
tags.sort(function (a, b) collation.compareString(1, a.tag, b.tag));
|
tags.sort((a, b) => collation.compareString(1, a.tag, b.tag));
|
||||||
|
|
||||||
for (let i=0; i<tags.length; i++) {
|
for (let i=0; i<tags.length; i++) {
|
||||||
this.addDynamicRow(tags[i], i+1);
|
this.addDynamicRow(tags[i], i+1);
|
||||||
|
@ -682,7 +682,7 @@
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
var tags = value.split(/\r\n?|\n/).map(function (val) val.trim());
|
var tags = value.split(/\r\n?|\n/).map(val => val.trim());
|
||||||
|
|
||||||
// Modifying existing tag with a single new one
|
// Modifying existing tag with a single new one
|
||||||
if (!isNew && tags.length < 2) {
|
if (!isNew && tags.length < 2) {
|
||||||
|
|
Loading…
Reference in New Issue
Block a user