clean up tree.go