Trim whitespaces for downloaded file