Fix end of condition