fix some bugs again