~ Small refactoring of tree