cleaning up json confusion