If the same logic is needed for both instances the conditions should be combined.

[source,sql,diff-id=1,diff-type=compliant]
----
IF (@SortOrder = 1 OR @SortOrder = 2)
  BEGIN
    SET @SortOrder = 0
    SELECT LastName FROM Employees ORDER BY LastName
  END
ELSE
  BEGIN
    SET @SortOrder = -1
    SELECT LastName FROM Employees
  END
GO
----