@gearbox-protocol/deploy-tools 5.3.12 → 5.3.14

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/index.mjs +12 -3
  2. package/package.json +2 -2
package/dist/index.mjs CHANGED
@@ -409246,9 +409246,18 @@ var AccountOpener = class {
409246
409246
  */
409247
409247
  async openCreditAccounts(targets) {
409248
409248
  await this.#prepareBorrower(targets);
409249
+ const toApprove = new AddressMap();
409249
409250
  for (const c of targets) {
409250
409251
  const cm = this.sdk.marketRegister.findCreditManager(c.creditManager);
409251
- await this.#approve(c.collateral, cm);
409252
+ const toApproveOnCM = toApprove.get(c.creditManager) ?? /* @__PURE__ */ new Set();
409253
+ toApproveOnCM.add(cm.underlying);
409254
+ toApprove.upsert(c.creditManager, toApproveOnCM);
409255
+ }
409256
+ for (const [cmAddr, tokens] of toApprove.entries()) {
409257
+ const cm = this.sdk.marketRegister.findCreditManager(cmAddr);
409258
+ for (const token of tokens) {
409259
+ await this.#approve(token, cm);
409260
+ }
409252
409261
  }
409253
409262
  for (let i = 0; i < targets.length; i++) {
409254
409263
  const target = targets[i];
@@ -417994,7 +418003,7 @@ function getRenderer(opts) {
417994
418003
  var package_default = {
417995
418004
  name: "@gearbox-protocol/deploy-tools",
417996
418005
  description: "Gearbox deploy tools",
417997
- version: "5.3.12",
418006
+ version: "5.3.14",
417998
418007
  homepage: "https://gearbox.fi",
417999
418008
  keywords: [
418000
418009
  "gearbox"
@@ -418037,7 +418046,7 @@ var package_default = {
418037
418046
  "@gearbox-protocol/deploy-tools-node": "0.0.0",
418038
418047
  "@gearbox-protocol/deploy-tools-shared": "0.0.0",
418039
418048
  "@gearbox-protocol/deploy-tools-types": "0.0.0",
418040
- "@gearbox-protocol/sdk": "^3.0.0-vfour.162",
418049
+ "@gearbox-protocol/sdk": "^3.0.0-vfour.164",
418041
418050
  "@gearbox-protocol/sdk-gov": "^2.33.2",
418042
418051
  "@types/lodash-es": "^4.17.12",
418043
418052
  "@types/node": "^22.10.5",
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@gearbox-protocol/deploy-tools",
3
3
  "description": "Gearbox deploy tools",
4
- "version": "5.3.12",
4
+ "version": "5.3.14",
5
5
  "homepage": "https://gearbox.fi",
6
6
  "keywords": [
7
7
  "gearbox"
@@ -44,7 +44,7 @@
44
44
  "@gearbox-protocol/deploy-tools-node": "0.0.0",
45
45
  "@gearbox-protocol/deploy-tools-shared": "0.0.0",
46
46
  "@gearbox-protocol/deploy-tools-types": "0.0.0",
47
- "@gearbox-protocol/sdk": "^3.0.0-vfour.162",
47
+ "@gearbox-protocol/sdk": "^3.0.0-vfour.164",
48
48
  "@gearbox-protocol/sdk-gov": "^2.33.2",
49
49
  "@types/lodash-es": "^4.17.12",
50
50
  "@types/node": "^22.10.5",