deleting unnecessary lines