Better rescue from no content.
Require ruby >= 1.9.3 (for JSON).