shoonya-sdk 0.4.6 → 0.4.7

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.
@@ -513,7 +513,7 @@ var Shoonya = class extends import_events.EventEmitter {
513
513
  const dateNow = (/* @__PURE__ */ new Date()).getDate();
514
514
  const optionExpiryDate = unformattedDate.getDate();
515
515
  const check = parseInt(match[1], 10);
516
- if (optionExpiryDate - dateNow < check)
516
+ if (Math.abs(optionExpiryDate - dateNow) < check)
517
517
  continue;
518
518
  }
519
519
  for (const { tsym, token } of optionChain.values) {
@@ -487,7 +487,7 @@ var Shoonya = class extends EventEmitter {
487
487
  const dateNow = (/* @__PURE__ */ new Date()).getDate();
488
488
  const optionExpiryDate = unformattedDate.getDate();
489
489
  const check = parseInt(match[1], 10);
490
- if (optionExpiryDate - dateNow < check)
490
+ if (Math.abs(optionExpiryDate - dateNow) < check)
491
491
  continue;
492
492
  }
493
493
  for (const { tsym, token } of optionChain.values) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "shoonya-sdk",
3
- "version": "0.4.6",
3
+ "version": "0.4.7",
4
4
  "description": "Wrapper around Shoonya API",
5
5
  "main": "dist/shoonya-sdk.js",
6
6
  "module": "dist/shoonya-sdk.mjs",