strip off whitespace when saving file