remove erroneous new line at end of file