A good idea is storing this `if` condition in a method like `is_user_related_to_project?` or something.