fix random node number bug