diff --git a/app/controllers/people_controller.rb b/app/controllers/people_controller.rb index 4dd0b5751ecd74d5d5dbb57d31c7d879a2b5a4f2..fdea0ad0bf842e87e6ec1afabdf06dabb5c18436 100644 --- a/app/controllers/people_controller.rb +++ b/app/controllers/people_controller.rb @@ -47,13 +47,12 @@ class PeopleController < ApplicationController if @person @profile = @person.profile @contact = current_user.contact_for(@person) - @is_contact = @person != current_user.person && @contact if @contact @aspects_with_person = @contact.aspects end - @commenting_disabled = !@contact + @commenting_disabled = (current_user.person.id != @person.id) && !@contact @posts = current_user.posts_from(@person).paginate :page => params[:page] @post_hashes = hashes_for_posts @posts diff --git a/app/views/people/show.html.haml b/app/views/people/show.html.haml index 491664192ff280601c5147ba5c41eb65451a6972..df078a437f6280e6b6c22e3f5d138075070db079 100644 --- a/app/views/people/show.html.haml +++ b/app/views/people/show.html.haml @@ -17,7 +17,7 @@ = link_to t('_photos'), person_photos_path(@person) .span-8.append-1.last - = render :partial => 'people/profile_sidebar', :locals => {:person => @person, :is_contact => @is_contact} + = render :partial => 'people/profile_sidebar', :locals => {:person => @person, :is_contact => @contact} .span-15.last - unless @contact || current_user.person == @person