fix some bug nearly finish