Update script.js

Fixing a bug where if there is an empty line in data.txt, it would crash the browser.
Merge pull request #1 from maxflav/patch-1

Update script.js