Cleared up code