zurb / orbit

454 stars 96 forks source link

calling 'replace' on undefined #44

Closed DrGonzo65 closed 13 years ago

DrGonzo65 commented 13 years ago

When using the default settings for the plugin, captions is true, thus throwing an error from jQuery on line 201:

_captionHTML = $(_captionLocation).html();

This occurs because _captionLocation is undefined if no data-caption attribute is attached to the element.

mkelly12 commented 13 years ago

Nice, thanks for the fix. I have applied it to the master branch and our refactor branch.