Commit df0526c4daa95132a9d4e1f36bb446ceb69d1ef1
1 parent
8f176d5f
Exists in
master
and in
28 other branches
Creating sample friendships The Right Way
Showing
1 changed file
with
1 additions
and
1 deletions
Show diff stats
script/sample-data
... | ... | @@ -40,7 +40,7 @@ rand(people.size * 3).times do |
40 | 40 | from = people.rand |
41 | 41 | to = people.rand |
42 | 42 | if from != to && !from.friends.include?(to) |
43 | - from.add_friend(to) | |
43 | + AddFriend.create!(:requestor => to, :target => from).finish | |
44 | 44 | end |
45 | 45 | print '.'; $stdout.flush |
46 | 46 | end | ... | ... |