[collapse() method check](https://w3c.github.io/selection-api/#dom-selection-collapse) has this check: > If node is a [DocumentType](https://dom.spec.whatwg.org/#documenttype), throw an [InvalidNodeTypeError](https://webidl.spec.whatwg.org/#invalidnodetypeerror) exception and abort these steps. However, [setBaseAndExtent() method](https://w3c.github.io/selection-api/#dom-selection-setbaseandextent) does not have it.