Removing unnecessary leftovers