From e2994ec7fa79194c0bbc73b1c2c56d4addc9ce31 Mon Sep 17 00:00:00 2001 From: Logan Allen Date: Thu, 11 Feb 2021 17:46:36 -0600 Subject: [PATCH] contact-push-hook: kick on set-private, share on set-public --- pkg/arvo/app/contact-push-hook.hoon | 18 +++++++++++++++--- 1 file changed, 15 insertions(+), 3 deletions(-) diff --git a/pkg/arvo/app/contact-push-hook.hoon b/pkg/arvo/app/contact-push-hook.hoon index 251570481b..f65ad18b0c 100644 --- a/pkg/arvo/app/contact-push-hook.hoon +++ b/pkg/arvo/app/contact-push-hook.hoon @@ -111,7 +111,19 @@ |= =vase ^- [(list card) agent] =/ =update:store !<(update:store vase) - ?. ?=(%disallow -.update) [~ this] - :_ this - [%give %kick ~[resource+(en-path:res [our.bowl %''])] ~]~ + ?+ -.update [~ this] + %disallow + :_ this + [%give %kick ~[resource+(en-path:res [our.bowl %''])] ~]~ + :: + %set-public + :_ this + ?. public.update + [%give %kick ~[resource+(en-path:res [our.bowl %''])] ~]~ + %+ murn ~(tap in scry-groups:grp) + |= rid=res + ?: =(our.bowl entity.rid) ~ + ?. (is-managed:grp rid) ~ + `(poke-self:pass:io contact-share+!>([%share entity.rid])) + == --