Skip to content
Merged
Show file tree
Hide file tree
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
5 changes: 5 additions & 0 deletions .changeset/quiet-tires-repair.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"@orca-so/whirlpools-rust": patch
---

Fix Dynamic TickArray handling in swap_instructions function
4 changes: 2 additions & 2 deletions docs/rust/Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

4 changes: 2 additions & 2 deletions rust-sdk/whirlpool/src/swap.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@ use std::{
};

use orca_whirlpools_client::{
get_oracle_address, get_tick_array_address, AccountsType, FixedTickArray, Oracle,
get_oracle_address, get_tick_array_address, AccountsType, TickArray, Oracle,
RemainingAccountsInfo, RemainingAccountsSlice, SwapV2, SwapV2InstructionArgs, Whirlpool,
};
use orca_whirlpools_core::{
Expand Down Expand Up @@ -102,7 +102,7 @@ async fn fetch_tick_arrays_or_default(
.iter()
.map(|x| {
x.as_ref()
.and_then(|y| FixedTickArray::from_bytes(&y.data).ok())
.and_then(|y| TickArray::from_bytes(&y.data).ok())
})
.map(|x| x.map(|y| y.into()))
.collect();
Expand Down
Loading