mirror of https://gitlab.com/litecord/litecord.git
relationships: move the calls to sub_friend instead of unsub
lol
This commit is contained in:
parent
c337c1c349
commit
2ffa3cb82d
|
|
@ -46,6 +46,10 @@ async def _unsub_friend(user_id, peer_id):
|
|||
await app.dispatcher.unsub('friend', user_id, peer_id)
|
||||
await app.dispatcher.unsub('friend', peer_id, user_id)
|
||||
|
||||
async def _sub_friend(user_id, peer_id):
|
||||
await app.dispatcher.sub('friend', user_id, peer_id)
|
||||
await app.dispatcher.sub('friend', peer_id, user_id)
|
||||
|
||||
# dispatch presence update to the user and peer about
|
||||
# eachother's presence.
|
||||
user_pres, peer_pres = await app.presence.friend_presences(
|
||||
|
|
@ -56,11 +60,6 @@ async def _unsub_friend(user_id, peer_id):
|
|||
await _dispatch_single_pres(peer_id, user_pres)
|
||||
|
||||
|
||||
async def _sub_friend(user_id, peer_id):
|
||||
await app.dispatcher.sub('friend', user_id, peer_id)
|
||||
await app.dispatcher.sub('friend', peer_id, user_id)
|
||||
|
||||
|
||||
async def make_friend(user_id: int, peer_id: int,
|
||||
rel_type=RelationshipType.FRIEND.value):
|
||||
_friend = RelationshipType.FRIEND.value
|
||||
|
|
|
|||
Loading…
Reference in New Issue