clean trailing whitespaces