contact-hook: no-op on accepted invite
The contact-hook was attempting to join a group upon it's invite being
accepted. However, the join poke is also sent from the frontend, causing
a potential race condition. Changes contact-hook to no-op on an
%invite-update.
(fact-group-update:cc wire !<(update:group-store q.cage.sign))
[cards this]
::
- %invite-update
- =^ cards state
- (fact-invite-update:cc wire !<(invite-update q.cage.sign))
- [cards this]
+ %invite-update [~ this]
==
==
::
[%pass / %agent [our.bol %invite-hook] %poke %invite-action !>(act)]
--
::
-++ fact-invite-update
- |= [wir=wire fact=invite-update]
- ^- (quip card _state)
- ?+ -.fact [~ state]
- %accepted
- =/ rid=resource
- (de-path:resource path.invite.fact)
- :_ state
- ~[(contact-view-poke %join rid)]
- ==
-::
++ group-hook-poke
|= =action:group-hook
^- card
