diff --git a/assets/watson.js b/assets/watson.js index 104095d..0ae651e 100644 --- a/assets/watson.js +++ b/assets/watson.js @@ -9,14 +9,11 @@ jQuery(function($){ | */ - $(document).ready( function() { - - var $watson_id = getUrlParameter('watson_id'); - var $watson_text = getUrlParameter('watson_text'); - if ($watson_id && $watson_text) { - $('#' + $watson_id).val($watson_text).focus(); - } - }); + var $watson_id = getUrlParameter('watson_id'); + var $watson_text = getUrlParameter('watson_text'); + if ($watson_id && $watson_text) { + $('#' + $watson_id).val($watson_text).focus(); + } function getUrlParameter(name) { return decodeURI( @@ -95,10 +92,8 @@ jQuery(function($){ var $watsonTypeahead = $('#watson-agent .typeahead'); var $watsonOverlay = $('#watson-overlay'); - $(document).ready( function() { - $watsonOverlay.click(function(){ - hideWatsonAgent(); - }); + $watsonOverlay.click(function(){ + hideWatsonAgent(); }); // support buttons created dynamically