switched to using res.json and removed json indentation