Use variable $ which is passed to closure, jQuery var might be undefined
Do not use jQuery if it's undefined
Merge pull request #1231 from blackbyte-pl/master

jQuery might be undefined, bad variable in use