diff --git a/pallets/gear/src/lib.rs b/pallets/gear/src/lib.rs index b28b79e53c4..4204074235c 100644 --- a/pallets/gear/src/lib.rs +++ b/pallets/gear/src/lib.rs @@ -1894,13 +1894,19 @@ pub mod pallet { .try_into() .unwrap_or_else(|_| unreachable!("Signal message sent to user")); + let existence_requirement = if keep_alive { + ExistenceRequirement::KeepAlive + } else { + ExistenceRequirement::AllowDeath + }; + CurrencyOf::::transfer( &who, &::AccountId::from_origin( message.destination().into_origin(), ), value.unique_saturated_into(), - ExistenceRequirement::AllowDeath, + existence_requirement, )?; Pallet::::deposit_event(Event::UserMessageSent {