Remove ES6-specific syntax in amsify suggestags

It was causing JavaScript to stop working completely on old browsers
which don't support this syntax.
This commit is contained in:
Javi Martín
2021-07-06 13:56:28 +02:00
parent f888ccaf7d
commit 4153e52e70

View File

@@ -506,7 +506,11 @@ var AmsifySuggestags;
return listHTML;
},
addTag : function(value, animate=true) {
addTag : function(value, animate) {
if(animate === undefined) {
animate = true;
}
if(!value) {
return;
}
@@ -624,7 +628,11 @@ var AmsifySuggestags;
}
},
removeTag: function(value, animate=true) {
removeTag: function(value, animate) {
if(animate === undefined) {
animate = true;
}
var _self = this;
$findTags = $(this.selectors.inputArea).find('[data-val="'+value+'"]');
if($findTags.length) {