Removes redundant code