]> source.dussan.org Git - jquery-ui.git/commitdiff
Autocomplete: Set context for ajax requests instead of relying on default context...
authorScott González <scott.gonzalez@gmail.com>
Sat, 11 Feb 2012 13:15:24 +0000 (08:15 -0500)
committerScott González <scott.gonzalez@gmail.com>
Sat, 11 Feb 2012 13:15:54 +0000 (08:15 -0500)
(cherry picked from commit 041cb39a6667e3637a40fad6ef952da476f2af97)

ui/jquery.ui.autocomplete.js

index bc32bb9878eb9c61893334631b8a64059c318281..8857e8613625d00d4e38cdd436bb6b48e8767301 100644 (file)
@@ -268,7 +268,9 @@ $.widget( "ui.autocomplete", {
                                        url: url,
                                        data: request,
                                        dataType: "json",
-                                       autocompleteRequest: ++requestIndex,
+                                       context: {
+                                               autocompleteRequest: ++requestIndex
+                                       },
                                        success: function( data, status ) {
                                                if ( this.autocompleteRequest === requestIndex ) {
                                                        response( data );