graph-delete thread: properly remove entry from metadata-store and hook

This commit is contained in:
Logan Allen 2021-01-06 12:49:13 -06:00
parent dde827b2d3
commit c99bf65d81

View File

@ -33,7 +33,7 @@
(pure:m (need ugroup)) (pure:m (need ugroup))
:: ::
++ delete-graph ++ delete-graph
|= rid=resource |= [group-rid=resource rid=resource]
=/ m (strand ,~) =/ m (strand ,~)
^- form:m ^- form:m
;< =bowl:spider bind:m get-bowl:strandio ;< =bowl:spider bind:m get-bowl:strandio
@ -43,12 +43,9 @@
(poke-our %graph-push-hook %push-hook-action !>([%remove rid])) (poke-our %graph-push-hook %push-hook-action !>([%remove rid]))
;< ~ bind:m ;< ~ bind:m
%+ poke-our %metadata-hook %+ poke-our %metadata-hook
metadata-hook-action+!>([%remove (en-path:resource rid)])
;< ~ bind:m
%+ poke-our %metadata-store
:- %metadata-action :- %metadata-action
!> :+ %remove !> :+ %remove
(en-path:resource rid) (en-path:resource group-rid)
[%graph (en-path:resource rid)] [%graph (en-path:resource rid)]
(pure:m ~) (pure:m ~)
-- --
@ -69,11 +66,14 @@
(scry-group u.ugroup-rid) (scry-group u.ugroup-rid)
?. hidden.group ?. hidden.group
;< ~ bind:m ;< ~ bind:m
(delete-graph rid.action) (delete-graph u.ugroup-rid rid.action)
(pure:m !>(~)) (pure:m !>(~))
;< ~ bind:m ;< ~ bind:m
(poke-our %group-store %group-action !>([%remove-group rid.action ~])) (poke-our %group-store %group-action !>([%remove-group rid.action ~]))
;< ~ bind:m ;< ~ bind:m
(poke-our %group-push-hook %push-hook-action !>([%remove rid.action])) (poke-our %group-push-hook %push-hook-action !>([%remove rid.action]))
;< ~ bind:m (delete-graph rid.action) ;< ~ bind:m (delete-graph u.ugroup-rid rid.action)
;< ~ bind:m
%+ poke-our %metadata-hook
metadata-hook-action+!>([%remove (en-path:resource u.ugroup-rid)])
(pure:m !>(~)) (pure:m !>(~))