If you insist on stripping a single space, at least use `rtrim()`.