digicorp / propeller

Propeller - Develop more, Code less. Propeller is a front-end responsive framework based on Google's Material Design Standards & Bootstrap.
http://propeller.in
MIT License
1.13k stars 141 forks source link

parentSelector variable with 'undefined' failed to check #72

Closed jewijaya closed 5 years ago

jewijaya commented 6 years ago

I found a problem when trying using propeller with jquery 3.2.1 & 3.3.1 maybe is not about jquery version, because i check with jquery 1.12.4 is working

image

The problem seems from propeller.js in commons.attachParentSelector function. It seem failed while trying to evaluate parentSelector which has undefined value

My simple fix is, just added some new conditionals while evaluate parentSelector value

if (parentSelector && parentSelector !== '' && parentSelector.length > 0)

This 'parentSelector' conditional will guarantee that parentSelector for this value

https://stackoverflow.com/questions/5515310/is-there-a-standard-function-to-check-for-null-undefined-or-blank-variables-in

monika-digicorp commented 6 years ago

@jewijaya Thank you for bringing it to our notice. We will check it and make the necessary changes.

xeboo commented 6 years ago

Thx, that works