Added some inteligence to json clone