remove a lot of trailing whitespace