diff --git a/js/search_api_autocomplete.js b/js/search_api_autocomplete.js index 1226e94..ba98d35 100644 --- a/js/search_api_autocomplete.js +++ b/js/search_api_autocomplete.js @@ -6,6 +6,9 @@ (function ($) { var oldSelect = Drupal.autocomplete.options.select; + // Override the "select" option of the jQueryUI auto-complete to + // add the functionality to submit the form if the auto_submit class + // is present. Drupal.autocomplete.options.select = function (event, ui) { oldSelect.call(this, event, ui); if ($(this).hasClass('auto_submit')) {