The second expression doesn't make much sense (`!` incorrectly placed, and non-standard `tagName` used).  It should probably be:

```js
sel.anchorNode.get('nodeName') !== 'P' 
```