diff --git a/js/search/search_form_criteria.js b/js/search/search_form_criteria.js index 30c6385f1..415c5649a 100644 --- a/js/search/search_form_criteria.js +++ b/js/search/search_form_criteria.js @@ -152,7 +152,7 @@ $(function() _initChooseDefaultOperator: function() { //if the class has an index, in order to maximize the performance, we force the default operator to "equal" - if (this.options.field.has_index && typeof this.options.available_operators['='] == 'object' && this.options.values.length == 0) + if (this.options.field.has_index && this.options.available_operators['='] != null && typeof this.options.available_operators['='] == 'object' && this.options.values.length == 0) { this.options.operator = '='; this.options.available_operators['='].rank = -1;//we want it to be the first displayed