Skip to content

Commit

Permalink
When invoking manually, make sure the $ selection is not empty
Browse files Browse the repository at this point in the history
I was just checking to see what happens when invoking the modal manually, and I used the $('#sticky') example from examples. As we don't have a #sticky element in the DOM, the modal just display the blocker.
  • Loading branch information
adiospace committed Feb 18, 2012
1 parent 87d4e6b commit f750f2a
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion jquery.modal.js
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@
};

$.fn.modal = function(options){
new $.modal(this, options);
if(this.length === 1) { new $.modal(this, options); }
return this;
};

Expand Down

0 comments on commit f750f2a

Please sign in to comment.