fixed old bugs