Updated js snippet
Merge pull request #13 from nitriques/patch-1

Updated js snippet