In this case that can be done, if you wish.
But in general I have the oposite opinion on inline assigments in conditions, because then someone may try write something like this:
```else if invalidContent() or assetsChanged (doc = createDocument xhr.responseText)``` 
(fully: https://github.com/rails/turbolinks/blob/master/lib/assets/javascripts/turbolinks.js.coffee#L170-L174)
which literally hurts