From df4f4deb1f54e4baa77d7cfcf81945df9693933b Mon Sep 17 00:00:00 2001 From: nathangray Date: Fri, 3 Nov 2017 14:37:46 -0600 Subject: [PATCH] Etemplate - Make sure to not return an empty string, it will fail when queried --- api/js/etemplate/et2_widget_taglist.js | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/api/js/etemplate/et2_widget_taglist.js b/api/js/etemplate/et2_widget_taglist.js index 3c7cbc64bc..b3be0d080f 100644 --- a/api/js/etemplate/et2_widget_taglist.js +++ b/api/js/etemplate/et2_widget_taglist.js @@ -479,6 +479,12 @@ var et2_taglist = (function(){ "use strict"; return et2_selectbox.extend([et2_IR } this._query_server = false; + // Make sure we don't give an empty string, that fails when we try to query + if(return_value == this.options.autocomplete_url && !return_value) + { + return_value = []; + } + // Turn on local filtering, or trust server to do it cfg.mode = typeof return_value === 'string' ? 'remote' : 'local';