added recursive impl for toJSOJSON for object