mirror of
https://github.com/urbit/shrub.git
synced 2024-11-28 22:33:06 +03:00
pull-hook: no-op on double add
If we receive an %add poke for a resource we are already pulling, no-op instead of crashing. This should prevent crashes upon repulling a resource after a breach of the host.
This commit is contained in:
parent
516423b853
commit
f658d99c76
@ -225,7 +225,8 @@
|
||||
++ add
|
||||
|= [=ship =resource]
|
||||
~| resource
|
||||
?< (~(has by tracking) resource)
|
||||
?: (~(has by tracking) resource)
|
||||
[~ state]
|
||||
=. tracking
|
||||
(~(put by tracking) resource ship)
|
||||
:_ state
|
||||
|
Loading…
Reference in New Issue
Block a user