Bug 32030: 30063 follow-up

In case one option is "0"

Signed-off-by: Jonathan Field <jonathan.field@ptfs-europe.com>

Signed-off-by: Martin Renvoize <martin.renvoize@ptfs-europe.com>
Signed-off-by: Kyle M Hall <kyle@bywatersolutions.com>
Signed-off-by: Tomas Cohen Arazi <tomascohen@theke.io>
This commit is contained in:
Jonathan Druart 2022-05-04 16:22:03 +02:00 committed by Tomas Cohen Arazi
parent ff2bf0d5a3
commit ccf18550b0
Signed by: tomascohen
GPG key ID: 0A272EA1B2F3C15F

View file

@ -866,7 +866,7 @@ jQuery.fn.dataTable.ext.errMode = function(settings, note, message) {
// FIXME eval here is bad and dangerous, how do we workaround that?
$(eval(filter_type)).each(function(){
let o = $('<option value="%s">%s</option>'.format(this._id, this._str));
if ( existing_search == this._id ) {
if ( existing_search === this._id ) {
o.prop("selected", "selected");
}
o.appendTo(select);