Irrelon / jquery-lang-js

i18n Allow instant language switching on HTML pages without reloading the page.
https://www.irrelon.com
362 stars 132 forks source link

Cannot set property 'langToken' of undefined #103

Closed uoiszero closed 4 years ago

uoiszero commented 7 years ago

at line 299, when node type is 3, nodes length will longer then nodeObjArray length. so

if(nodeObjArray.length === 1){ nodeObjArray[0].langToken = elem.data('langToken'); }

maybe better

Irrelon commented 7 years ago

Hi ya,

Could you put together a pull request for this change? That way you will be properly credited with the fix.

Thanks,

Rob