toJSON no longer results in an infinite loop, returns simple objects