Trim any trailing whitespace left after munging parameters etc.