Fixed bug where user input an invalid getfile path and the tree wasn't cleaned up