fix all possible errors