class User < ApplicationRecord
require "xml/libxml"
- self.ignored_columns = ["nearby"]
-
has_many :traces, -> { where(:visible => true) }
has_many :diary_entries, -> { order(:created_at => :desc) }
has_many :diary_comments, -> { order(:created_at => :desc) }
end
def is_friends_with?(new_friend)
- friendships.where(:befriendee => new_friend).exists?
+ friendships.exists?(:befriendee => new_friend)
end
##