Switch to using String.prototype.trim from String.trim as it's more-widely available.