diff --git a/src/bin/lib/parse.rs b/src/bin/lib/parse.rs index 99f24cb..17f42f2 100644 --- a/src/bin/lib/parse.rs +++ b/src/bin/lib/parse.rs @@ -7,7 +7,7 @@ use tycho_core::{ dto::{Chain, ProtocolComponent}, Bytes, }; -use tycho_execution::encoding::models::{Solution, Swap}; +use tycho_execution::encoding::models::{NativeAction, Solution, Swap}; pub fn parse_solution(input: Value) -> Result> { let obj = input @@ -58,7 +58,15 @@ pub fn parse_solution(input: Value) -> Result Some(NativeAction::Wrap), + "unwrap" => Some(NativeAction::Unwrap), + _ => None, // Default to None + }) + .flatten(), direct_execution: obj .get("direct_execution") .and_then(|v| v.as_bool())