1. Fixed bugs in getJSON
2. Made download guess at the filename if it is not provided
3. Added mocha tests!