@triadxyz/triad-protocol 2.3.2-beta → 2.3.3-beta

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 (2) hide show
  1. package/dist/trade.js +5 -1
  2. package/package.json +1 -1
package/dist/trade.js CHANGED
@@ -742,7 +742,11 @@ class Trade {
742
742
  let adjustedPrice = orderPrice;
743
743
  if (feeBps > 0) {
744
744
  const priceSpread = new bn_js_1.default(1000000).sub(orderPrice);
745
- const fee = priceSpread.mul(new bn_js_1.default(feeBps)).div(new bn_js_1.default(10000));
745
+ const fee = priceSpread
746
+ .mul(new bn_js_1.default(feeBps))
747
+ .div(new bn_js_1.default(10000))
748
+ .mul(orderPrice)
749
+ .div(new bn_js_1.default(1000000));
746
750
  adjustedPrice = orderPrice.add(fee);
747
751
  }
748
752
  const maxSharesForPrice = remainingUSDC
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@triadxyz/triad-protocol",
3
- "version": "2.3.2-beta",
3
+ "version": "2.3.3-beta",
4
4
  "main": "./dist/index.js",
5
5
  "module": "./dist/index.js",
6
6
  "types": "./dist/index.d.ts",