Deleteing unneeded lines