Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

XCM MultiAssets: sort after reanchoring #2129

Merged
merged 4 commits into from
Nov 2, 2023
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion polkadot/xcm/src/v3/multiasset.rs
Original file line number Diff line number Diff line change
Expand Up @@ -694,7 +694,9 @@ impl MultiAssets {
target: &MultiLocation,
context: InteriorMultiLocation,
) -> Result<(), ()> {
self.0.iter_mut().try_for_each(|i| i.reanchor(target, context))
self.0.iter_mut().try_for_each(|i| i.reanchor(target, context))?;
self.0.sort();
serban300 marked this conversation as resolved.
Show resolved Hide resolved
Ok(())
}

/// Return a reference to an item at a specific index or `None` if it doesn't exist.
Expand Down