Fix bug with tree splicing.