fix friends aggregation matcher
This commit is contained in:
parent
e98f3674dd
commit
f2be8e3702
|
@ -41,7 +41,8 @@ final class RelationApi(
|
|||
def fetchBlocking = RelationRepo blocking _
|
||||
|
||||
def fetchFriends(userId: ID) = coll.aggregate(Match(BSONDocument(
|
||||
"$or" -> BSONArray(BSONDocument("u1" -> userId), BSONDocument("u2" -> userId))
|
||||
"$or" -> BSONArray(BSONDocument("u1" -> userId), BSONDocument("u2" -> userId)),
|
||||
"r" -> Follow
|
||||
)), List(
|
||||
Group(BSONNull)(
|
||||
"u1" -> AddToSet("u1"),
|
||||
|
|
Loading…
Reference in a new issue