fix bug isTree