Skip to content
This repository was archived by the owner on Sep 10, 2023. It is now read-only.

Commit 5a4b941

Browse files
committed
Check url type before setting crossDomain. Fixes #247
1 parent ccdc354 commit 5a4b941

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/jquery.tokeninput.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -150,7 +150,7 @@ $.TokenList = function (input, url_or_data, settings) {
150150
var url = computeURL();
151151

152152
// Make a smart guess about cross-domain if it wasn't explicitly specified
153-
if(settings.crossDomain === undefined) {
153+
if(settings.crossDomain === undefined && typeof url === "string") {
154154
if(url.indexOf("://") === -1) {
155155
settings.crossDomain = false;
156156
} else {

0 commit comments

Comments
 (0)