fix lot of bug