js bug fixed in tree view