fix some bug, and some bug still exist