class Popular::Friendship

Friendship class. Provides self-referential join for popular_models and their friends

Private Instance Methods

create_friendship_profile!() click to toggle source
Calls superclass method
# File lib/popular/friendship.rb, line 23
def create_friendship_profile!
  if defined? ::FriendshipProfile
    super
  else
    warn "You have set friendship_profile: true in your popular model, however no FriendshipProfile model exists"
    warn "To fix this, run 'rails g model FriendshipProfile friendship:belongs_to'"
  end
end