Rails should then give you nice friendly access to your friends. You
don't even need to define a single reference in the user table! I
haven't used it myself yet, but I believe you'll get access to the
friends as an array :-
I have done a similar thing, and I created a friendship model for this.
The main reason is that in my system a friendship goes through multiple
stages. One user initiates a friendship request or invite, and the
other user either accepts (establishes a friendship) or rejects the
offer. Then at any time, one user might terminate the friendship. I
feel there is enough information here to warrant another model, and a
few columns in the friendship table.
I always query this model from the perspective of the active user (I
provide the user_id as a query condition), which avoids having to deal
with queries that include the user table twice. Then again, I'm kind of
a newbie, and maybe avoiding the problem is not your preference.
I don't have my code on me, but I hope this is a little helpful.