remove unnecessary new lines