mirror of
https://github.com/ilyakooo0/urbit.git
synced 2024-09-20 06:58:16 +03:00
ames: prevent crashes when corking an alien flow
The +on-cork handler asserts that the peer is known to us. This is the incorrect behaviour, because it will crash when corking a flow to a peer that is still an %alien. This can happen, for instance, when making a gall subscription for the first time and then corking it before the alien naturalises.
This commit is contained in:
parent
7940dd442b
commit
26aac7581a
@ -1778,8 +1778,9 @@
|
||||
|= =ship
|
||||
^+ event-core
|
||||
=/ ship-state (~(get by peers.ames-state) ship)
|
||||
::
|
||||
?> ?=([~ %known *] ship-state)
|
||||
:: XX: should go in alien-agenda maybe?
|
||||
?. ?=([~ %known *] ship-state)
|
||||
event-core
|
||||
=/ =peer-state +.u.ship-state
|
||||
=/ =channel [[our ship] now channel-state -.peer-state]
|
||||
::
|
||||
|
Loading…
Reference in New Issue
Block a user