app/controllers/wall_comments_controller.rb
# Return a the parent (user or photo or event) of the comment.
Return a the parent (user or photo or event) of the comment.
Return a the parent ( user or photo or event ) of the comment .
def parent
      if wall?
        @user
      elsif group_wall?
        @group
      elsif blog?
        @post
      elsif photo?
        @photo
      elsif event?
        @event
      elsif news_item?
        @news_item
      end
    end
def parent if wall? @user elsif group_wall? @group elsif blog? @post elsif photo? @photo elsif event? @event elsif news_item? @news_item end end
Return a the parent (user or photo or event) of the comment.
Return a the parent ( user or photo or event ) of the comment .