We could cache the version of trim we want to use:

```javascript
var trim = String.prototype.trim ?
  _.bind(String.prototype.trim.call, String.prototype.trim) :
  $.trim;
```