Skip to content

Commit c0be81c

Browse files
authored
fix: ata multiple position error (#146)
1 parent a590d77 commit c0be81c

File tree

3 files changed

+9
-2
lines changed

3 files changed

+9
-2
lines changed

CHANGELOG.md

+6
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,12 @@ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0
1919

2020
### Security
2121

22+
## @meteora-ag/dlmm [1.3.8] - PR #144
23+
24+
### Fixed
25+
26+
- Fix `getOrCreateATAInstruction` to use `createAssociatedTokenAccountIdempotentInstruction`
27+
2228
## @meteora-ag/dlmm [1.3.7] - PR #143
2329

2430
### Fixed

ts-client/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "@meteora-ag/dlmm",
3-
"version": "1.3.7",
3+
"version": "1.3.8",
44
"description": "",
55
"main": "./dist/index.js",
66
"module": "./dist/index.mjs",

ts-client/src/dlmm/helpers/index.ts

+2-1
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ import {
44
TOKEN_PROGRAM_ID,
55
TokenAccountNotFoundError,
66
TokenInvalidAccountOwnerError,
7+
createAssociatedTokenAccountIdempotentInstruction,
78
createAssociatedTokenAccountInstruction,
89
createCloseAccountInstruction,
910
getAccount,
@@ -111,7 +112,7 @@ export const getOrCreateATAInstruction = async (
111112
e instanceof TokenAccountNotFoundError ||
112113
e instanceof TokenInvalidAccountOwnerError
113114
) {
114-
const ix = createAssociatedTokenAccountInstruction(
115+
const ix = createAssociatedTokenAccountIdempotentInstruction(
115116
payer,
116117
toAccount,
117118
owner,

0 commit comments

Comments
 (0)