From c5483212115f468c61c3a2209fc7739817a10602 Mon Sep 17 00:00:00 2001 From: Daniel Shiposha Date: Wed, 07 Sep 2022 13:56:48 +0000 Subject: [PATCH] fix(xcm): use is_some in transact barrier --- --- a/runtime/common/config/xcm/mod.rs +++ b/runtime/common/config/xcm/mod.rs @@ -135,16 +135,15 @@ .iter() .find(|inst| matches![inst, Instruction::Transact { .. }]); - match transact_inst { - Some(_) => { - log::warn!( - target: "xcm::barrier", - "transact XCM rejected" - ); + if transact_inst.is_some() { + log::warn!( + target: "xcm::barrier", + "transact XCM rejected" + ); - Err(()) - } - None => Ok(()), + Err(()) + } else { + Ok(()) } } } -- gitstuff