Bug fixing and TermBrowser tree fix