Skip to content
Browse files

Added support for custom ajax handler.

  • Loading branch information...
1 parent 85c79aa commit bed2be7834644f76d3f509a7fb14cdce399835df sarunas committed Dec 14, 2012
Showing with 1 addition and 1 deletion.
  1. +1 −1 typeahead.js
View
2 typeahead.js
@@ -170,7 +170,7 @@
if (this.ajax.xhr) this.ajax.xhr.abort();
var params = this.ajax.preDispatch ? this.ajax.preDispatch(query) : { query : query }
- var jAjax = (this.ajax.method == "post") ? $.post : $.get;
+ var jAjax = this.ajax.transport || (this.ajax.method == "post") ? $.post : $.get;
this.ajax.xhr = jAjax(this.ajax.url, params, $.proxy(this.ajaxSource, this));
this.ajax.timerId = null;
}

0 comments on commit bed2be7

Please sign in to comment.
Something went wrong with that request. Please try again.