hedge-web3 0.1.8 → 0.1.12

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.
Files changed (30) hide show
  1. package/lib/index.js +80 -31
  2. package/lib/index.js.map +1 -1
  3. package/lib/types/src/Constants.d.ts +2 -1
  4. package/lib/types/src/Constants.d.ts.map +1 -1
  5. package/lib/types/src/index.d.ts +1 -0
  6. package/lib/types/src/index.d.ts.map +1 -1
  7. package/lib/types/src/instructions/liquidateVault.d.ts +2 -2
  8. package/lib/types/src/instructions/liquidateVault.d.ts.map +1 -1
  9. package/lib/types/src/instructions/loanVault.d.ts +2 -2
  10. package/lib/types/src/instructions/loanVault.d.ts.map +1 -1
  11. package/lib/types/src/instructions/redeemVault.d.ts +2 -2
  12. package/lib/types/src/instructions/redeemVault.d.ts.map +1 -1
  13. package/lib/types/src/instructions/refreshOraclePrice.d.ts +11 -0
  14. package/lib/types/src/instructions/refreshOraclePrice.d.ts.map +1 -0
  15. package/lib/types/src/instructions/withdrawStakingPool.d.ts.map +1 -1
  16. package/lib/types/src/instructions/withdrawVault.d.ts +2 -2
  17. package/lib/types/src/instructions/withdrawVault.d.ts.map +1 -1
  18. package/lib/types/src/state/VaultAccount.d.ts +0 -2
  19. package/lib/types/src/state/VaultAccount.d.ts.map +1 -1
  20. package/lib/types/tsconfig.base.tsbuildinfo +1 -1
  21. package/package.json +1 -1
  22. package/src/Constants.ts +6 -7
  23. package/src/index.ts +1 -0
  24. package/src/instructions/liquidateVault.ts +8 -11
  25. package/src/instructions/loanVault.ts +7 -10
  26. package/src/instructions/redeemVault.ts +4 -7
  27. package/src/instructions/refreshOraclePrice.ts +71 -0
  28. package/src/instructions/withdrawStakingPool.ts +2 -0
  29. package/src/instructions/withdrawVault.ts +10 -13
  30. package/src/state/VaultAccount.ts +0 -4
@@ -21,9 +21,6 @@ export class VaultAccount {
21
21
  /** The minimum collateral ratio this vault must maintain to not be subject to liquidation. */
22
22
  minCollateralRatio: Decimal
23
23
 
24
- /** The SOL/USD price at which this vault is subject to liquidation */
25
- liquidationPrice: number
26
-
27
24
  /** Current State of the vautl ("Open", "Closed", "Liquidated") */
28
25
  vaultStatus: string
29
26
 
@@ -33,7 +30,6 @@ export class VaultAccount {
33
30
  this.debt = vault.debt.toNumber()
34
31
  this.deposited = vault.deposited.toNumber()
35
32
  this.minCollateralRatio = DecimalFromU128(vault.minCollateralRatio)
36
- this.liquidationPrice = vault.liquidationPrice.toNumber()
37
33
  this.vaultStatus = Object.keys(vault.vaultStatus)[0]
38
34
  }
39
35