TrimEnd should suffice. I'll update it.