Revert "Use JSON.generate instead of #to_json"

This reverts commit b11cf395df849745c14aa0afbb80521df378883c.

Closes #86.