<div class="col-sm-6 col-md-4 col-lg-3 my-3 profile-box">
  <%= profile_picture_link(profile) %>
  <div><%= link_to profile.fullname, profile %></div>
  <div class="profile-subtitle"><%= profile.main_topic_or_first_topic.truncate(60) if profile.main_topic_or_first_topic %></div>
</div>

<% if profile %>
  <div class="col-sm-6 col-md-4 col-lg-3 my-3 profile-box">
    <%= profile_picture_link(profile) %>
      <div>
        <%= link_to profile.fullname, profile %>
      </div>
      <div class="profile-subtitle">
        <%= profile.main_topic_or_first_topic.truncate(60) if profile.main_topic_or_first_topic %>
      </div>
  </div>
<% end %>

Make sure a profile exists in the partial
Make sure a profile exists in the partial
