Okay, I see what you are saying.  This might work:
```javascript
var next = exports.next = function() {
  var elem = this[0];
  while ((elem && elem = elem.next)) if (isTag(elem)) return this.make(elem);
  return this;
};
```
Adding the check into the while condition, the check has to happen before trying to access `this.next`.