merge merkle tree

- adding  PR for comments
OK for the moment, in future we'd want to support multiple hash types and therefore empty hash will change. That can wait for the moment.