future_moves: move out and_then

This commit is contained in:
Simon Gardling 2025-03-25 12:54:27 -04:00
parent 072dd6daf1
commit e1207153ab
Signed by: titaniumtown
GPG Key ID: 9AB28AC10ECE533D

View File

@ -545,7 +545,8 @@ impl FutureMoves {
.map(|mut node| { .map(|mut node| {
node.parent = node node.parent = node
.parent .parent
.and_then(|parent| index_map.get(parent).and_then(|&x| x)); .and_then(|parent| index_map.get(parent))
.and_then(|&x| x);
for c in node.children.as_mut_slice() { for c in node.children.as_mut_slice() {
*c = index_map *c = index_map