@@ -88,20 +88,22 @@ function aseWaitClicked(e) {
88
88
}
89
89
}
90
90
91
- /*
92
- * Overridable method called before autocomplete container is loaded with result data.
93
- * This method is overridden to dynamically change the autocomplete result list size
94
- * @param sQuery {String} Original request.
95
- * @param oResponse {Object} Response object.
96
- * @param oPayload {MIXED} (optional) Additional argument(s)
97
- * @return {Boolean } Return true to continue loading data, false to cancel.
98
-
99
- */
100
- YAHOO . widget . AutoComplete . prototype . doBeforeLoadData = function ( sQuery , oResponse , oPayload ) {
101
- if ( oResponse . results . length != 0 ) {
102
- YAHOO . widget . AutoComplete . prototype . maxResultsDisplayed = oResponse . results . length ;
103
- }
104
- return true ;
91
+ if ( window . YAHOO ) {
92
+ /*
93
+ * Fix for the YUI-based autocomplete field, not needed since Jenkins 2.473.
94
+ * Overridable method called before autocomplete container is loaded with result data.
95
+ * This method is overridden to dynamically change the autocomplete result list size
96
+ * @param sQuery {String} Original request.
97
+ * @param oResponse {Object} Response object.
98
+ * @param oPayload {MIXED} (optional) Additional argument(s)
99
+ * @return {Boolean } Return true to continue loading data, false to cancel.
100
+ */
101
+ YAHOO . widget . AutoComplete . prototype . doBeforeLoadData = function ( sQuery , oResponse , oPayload ) {
102
+ if ( oResponse . results . length != 0 ) {
103
+ YAHOO . widget . AutoComplete . prototype . maxResultsDisplayed = oResponse . results . length ;
104
+ }
105
+ return true ;
106
+ }
105
107
}
106
108
107
109
function resetFields ( credentialElement ) {
0 commit comments