removes unwanted lines