try fix some bugs