If statement syntax fix