Another workaround for JSON.dump