@drift-labs/sdk 2.112.0-beta.2 → 2.112.0-beta.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/VERSION CHANGED
@@ -1 +1 @@
1
- 2.112.0-beta.2
1
+ 2.112.0-beta.3
@@ -478,7 +478,14 @@ class DLOB {
478
478
  }
479
479
  for (const askGenerator of askGenerators) {
480
480
  for (const ask of askGenerator) {
481
- if ((0, __1.isOrderExpired)(ask.order, ts, true, 25)) {
481
+ if (ask.isSignedMsg &&
482
+ slot.gt(ask.order.slot.addn(ask.order.auctionDuration))) {
483
+ this.orderLists
484
+ .get(marketTypeStr)
485
+ .get(marketIndex)
486
+ .signedMsg.bid.remove(ask.order, ask.userAccount);
487
+ }
488
+ else if ((0, __1.isOrderExpired)(ask.order, ts, true, 25)) {
482
489
  nodesToFill.push({
483
490
  node: ask,
484
491
  makerNodes: [],
@@ -478,7 +478,14 @@ class DLOB {
478
478
  }
479
479
  for (const askGenerator of askGenerators) {
480
480
  for (const ask of askGenerator) {
481
- if ((0, __1.isOrderExpired)(ask.order, ts, true, 25)) {
481
+ if (ask.isSignedMsg &&
482
+ slot.gt(ask.order.slot.addn(ask.order.auctionDuration))) {
483
+ this.orderLists
484
+ .get(marketTypeStr)
485
+ .get(marketIndex)
486
+ .signedMsg.bid.remove(ask.order, ask.userAccount);
487
+ }
488
+ else if ((0, __1.isOrderExpired)(ask.order, ts, true, 25)) {
482
489
  nodesToFill.push({
483
490
  node: ask,
484
491
  makerNodes: [],
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@drift-labs/sdk",
3
- "version": "2.112.0-beta.2",
3
+ "version": "2.112.0-beta.3",
4
4
  "main": "lib/node/index.js",
5
5
  "types": "lib/node/index.d.ts",
6
6
  "browser": "./lib/browser/index.js",
package/src/dlob/DLOB.ts CHANGED
@@ -934,7 +934,15 @@ export class DLOB {
934
934
 
935
935
  for (const askGenerator of askGenerators) {
936
936
  for (const ask of askGenerator) {
937
- if (isOrderExpired(ask.order, ts, true, 25)) {
937
+ if (
938
+ ask.isSignedMsg &&
939
+ slot.gt(ask.order.slot.addn(ask.order.auctionDuration))
940
+ ) {
941
+ this.orderLists
942
+ .get(marketTypeStr)
943
+ .get(marketIndex)
944
+ .signedMsg.bid.remove(ask.order, ask.userAccount);
945
+ } else if (isOrderExpired(ask.order, ts, true, 25)) {
938
946
  nodesToFill.push({
939
947
  node: ask,
940
948
  makerNodes: [],