Started refactoring MerkleTree, by getting rid of element and commit as
cached elements and instead loading on demand - much simpler. Fixed
nasty bug in JsonElement that was creating keys based on value not
digest. I guess the tests ought to have still worked, but disapointed
not to have picked up sooner.