I see. I would change things to:

~~~ { .ruby }
if user && user.entity
  set_entity(...) unless entity_present?(...)
  set_entity(...) unless entity_present?(...)
end
~~~

But you might ding me on the trailing conditionals ;).

I'll give it some thought and resolve things somehow.