File tree Expand file tree Collapse file tree 2 files changed +8
-1
lines changed
polkadot/xcm/pallet-xcm/src Expand file tree Collapse file tree 2 files changed +8
-1
lines changed Original file line number Diff line number Diff line change @@ -3712,7 +3712,6 @@ impl<T: Config> xcm_executor::traits::AssetLock for Pallet<T> {
37123712 use xcm_executor:: traits:: LockError :: * ;
37133713 let sovereign_account = T :: SovereignAccountOf :: convert_location ( & owner) . ok_or ( BadOwner ) ?;
37143714 let amount = T :: CurrencyMatcher :: matches_fungible ( & asset) . ok_or ( UnknownAsset ) ?;
3715- ensure ! ( T :: Currency :: free_balance( & sovereign_account) >= amount, AssetNotOwned ) ;
37163715 let locks = LockedFungibles :: < T > :: get ( & sovereign_account) . unwrap_or_default ( ) ;
37173716 let item_index =
37183717 locks. iter ( ) . position ( |x| x. 1 . try_as :: < _ > ( ) == Ok ( & unlocker) ) . ok_or ( NotLocked ) ?;
Original file line number Diff line number Diff line change 1+ title: Remove free balance check in prepare_unlock
2+ doc:
3+ - audience: Runtime Dev
4+ description: The free balance check during unlocking is unnecessary since a lock can cover both free and reserved
5+ balances. Removing it allows locks to be cleared even if part of the locked funds is reserved or already slashed.
6+ crates:
7+ - name: pallet-xcm
8+ bump: patch
You can’t perform that action at this time.
0 commit comments