Fix previous change for Internet Explorer

This is for #36. Internet Explorer 9,10 don't support `trimRight()`