Remove unnecessary new line characters