From 494d1086f93eca6c6b4aab45d831f8f2c103b1ee Mon Sep 17 00:00:00 2001 From: Omar Date: Tue, 29 Oct 2024 13:50:40 +0300 Subject: [PATCH] Move assert methods to be permitted in the `PoolRedemptionDetector` --- .../traverser/types/pool_redemption.rs | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/crates/radix-engine-toolkit/src/transaction_types/traverser/types/pool_redemption.rs b/crates/radix-engine-toolkit/src/transaction_types/traverser/types/pool_redemption.rs index 1d8fd60b..2c68a63c 100644 --- a/crates/radix-engine-toolkit/src/transaction_types/traverser/types/pool_redemption.rs +++ b/crates/radix-engine-toolkit/src/transaction_types/traverser/types/pool_redemption.rs @@ -82,7 +82,12 @@ impl StaticAnalysisCallback for PoolRedemptionDetector { | InstructionV2::TakeAllFromWorktop { .. } | InstructionV2::AssertWorktopContainsAny { .. } | InstructionV2::AssertWorktopContains { .. } - | InstructionV2::AssertWorktopContainsNonFungibles { .. } => true, + | InstructionV2::AssertWorktopContainsNonFungibles { .. } + | InstructionV2::AssertWorktopResourcesOnly { .. } + | InstructionV2::AssertWorktopResourcesInclude { .. } + | InstructionV2::AssertNextCallReturnsOnly { .. } + | InstructionV2::AssertNextCallReturnsInclude { .. } + | InstructionV2::AssertBucketContents { .. } => true, /* Not Permitted */ InstructionV2::BurnResource { .. } | InstructionV2::CallRoyaltyMethod { .. } @@ -109,12 +114,7 @@ impl StaticAnalysisCallback for PoolRedemptionDetector { | InstructionV2::CallFunction { .. } | InstructionV2::YieldToParent(_) | InstructionV2::YieldToChild(_) - | InstructionV2::VerifyParent(_) - | InstructionV2::AssertWorktopResourcesOnly(..) - | InstructionV2::AssertWorktopResourcesInclude(..) - | InstructionV2::AssertNextCallReturnsOnly(..) - | InstructionV2::AssertNextCallReturnsInclude(..) - | InstructionV2::AssertBucketContents(..) => false, + | InstructionV2::VerifyParent(_) => false, }; // Handle required method call