updated some bugs