Cleaned up the javascript a bit
Merge pull request #3 from Mechazawa/master

Cleaned up the javascript a bit