@defisaver/sdk 1.3.38 → 1.3.39

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.
@@ -1,7 +1,7 @@
1
1
  import { ActionWithL2 } from '../../ActionWithL2';
2
2
  import { EthAddress, uint8 } from '../../types';
3
3
  /**
4
- * AaveV3SetEModeAction - Set EMode for the proxy AaveV3 position
4
+ * AaveV3SetEModeAction - Set EMode for an AaveV3 position
5
5
  *
6
6
  * @category AaveV3
7
7
  */
@@ -10,7 +10,8 @@ export declare class AaveV3SetEModeAction extends ActionWithL2 {
10
10
  * @param useOnDefaultMarket If this is true it defaults to the hardcoded market in contract
11
11
  * @param market Address provider for specific market
12
12
  * @param categoryId ID of the category emode
13
+ * @param onBehalf Address of the position owner, defaults to proxy
13
14
  */
14
- constructor(useOnDefaultMarket: boolean, market: EthAddress, categoryId: uint8);
15
+ constructor(useOnDefaultMarket: boolean, market: EthAddress, categoryId: uint8, onBehalf?: EthAddress);
15
16
  encodeInputs(): string;
16
17
  }
@@ -1,7 +1,7 @@
1
1
  import { ActionWithL2 } from '../../ActionWithL2';
2
2
  import { getAddr } from '../../addresses';
3
3
  /**
4
- * AaveV3SetEModeAction - Set EMode for the proxy AaveV3 position
4
+ * AaveV3SetEModeAction - Set EMode for an AaveV3 position
5
5
  *
6
6
  * @category AaveV3
7
7
  */
@@ -10,11 +10,13 @@ export class AaveV3SetEModeAction extends ActionWithL2 {
10
10
  * @param useOnDefaultMarket If this is true it defaults to the hardcoded market in contract
11
11
  * @param market Address provider for specific market
12
12
  * @param categoryId ID of the category emode
13
+ * @param onBehalf Address of the position owner, defaults to proxy
13
14
  */
14
- constructor(useOnDefaultMarket, market, categoryId) {
15
- super('AaveV3SetEMode', getAddr('AaveV3SetEMode'), ['uint8', 'bool', 'address'], [categoryId, useOnDefaultMarket, market]);
15
+ constructor(useOnDefaultMarket, market, categoryId, onBehalf = getAddr('Empty')) {
16
+ super('AaveV3SetEMode', getAddr('AaveV3SetEMode'), ['uint8', 'bool', 'address', 'address'], [categoryId, useOnDefaultMarket, market, onBehalf]);
16
17
  this.mappableArgs = [
17
18
  this.args[2],
19
+ this.args[3],
18
20
  ];
19
21
  }
20
22
  encodeInputs() {
@@ -28,6 +30,8 @@ export class AaveV3SetEModeAction extends ActionWithL2 {
28
30
  // market
29
31
  encodedInput = encodedInput.concat(this.addressToBytes20(this.args[2]));
30
32
  }
33
+ // onBehalf
34
+ encodedInput = encodedInput.concat(this.addressToBytes20(this.args[3]));
31
35
  return encodedInput;
32
36
  }
33
37
  }
@@ -72,7 +72,7 @@ export const actionAddresses = {
72
72
  AaveV3Withdraw: '0x9D4e4b26A5E2e6Dad30C5d95F5cE78A8310F04C2',
73
73
  AaveV3SwapBorrowRateMode: '0x630F530Ac523C935cf2528E62D0A06F8900C5b1B',
74
74
  AaveV3Supply: '0x91b3fCCEA2f2e0622Cc1fb54E12f5ac5aAa55a87',
75
- AaveV3SetEMode: '0xBe7F735d7955e0461579E34266f41F928AE06D78',
75
+ AaveV3SetEMode: '0x496C7Ed730E2692Fa49085aF2a9B61aCb0Bc1336',
76
76
  AaveV3Payback: '0xe29265217D65F5a2ae41972E09C13E107D049004',
77
77
  AaveV3CollateralSwitch: '0x54A4d6cB567B2C6CDe4687c361b24fd912695DAb',
78
78
  AaveV3ClaimRewards: '0x998A2E9aaE03c11b7A9863C1F59c42A21fcf47D0',
@@ -370,7 +370,7 @@ export const actionAddresses = {
370
370
  AaveV3Borrow: '0x8CaDc8A911D19B9e4D36c9bAdE47d970f362BcEa',
371
371
  AaveV3CollateralSwitch: '0x20D1388Ffa0A2D6ff6328AD014C67051542ca3a8',
372
372
  AaveV3Payback: '0x88eb4050e89FecE4DF940109B0e58daF9B59e551',
373
- AaveV3SetEMode: '0x7F264737066b9b7D9729Fe9715abB97423D8b35B',
373
+ AaveV3SetEMode: '0xf00eEB0Cb7e6c86319022B105f261C5666535c24',
374
374
  AaveV3Supply: '0x7e49bdf4690feef64cb341ca46d1e3b45233a683',
375
375
  AaveV3SwapBorrowRateMode: '0xB8f0243b492f0e80feF5315Ba8692e7635481845',
376
376
  AaveV3Withdraw: '0xf19d045f6cFc04A5Ee5E0e8837b565b9f276e3F7',
@@ -432,7 +432,7 @@ export const actionAddresses = {
432
432
  AaveV3Borrow: '0x5786809DA660dB613994460F096F19fcd19eD4c9',
433
433
  AaveV3CollateralSwitch: '0x7AcdD66C13f87b1cBcE7B106a8C34E426475BADd',
434
434
  AaveV3Payback: '0xd88D5356e08dAd84E1576F89f4BF43C79a8BF0b2',
435
- AaveV3SetEMode: '0x99D5068d9520316e8D3B5136c0B6EA33C5E0c27e',
435
+ AaveV3SetEMode: '0x112515e9040D853C2928F9ff21D12Ac920BD6Db9',
436
436
  AaveV3Supply: '0xA2127f5C7E943c05B6a6A3a541557087F1F1287D',
437
437
  AaveV3SwapBorrowRateMode: '0x738042389A8d6B0F6D6ab009c42dfF84ebB737C0',
438
438
  AaveV3Withdraw: '0xbf492F869DdB1A18BB4F41b6c3059D9f882Fe7ff',
@@ -532,7 +532,7 @@ export const actionAddresses = {
532
532
  AaveV3Withdraw: '0x1d2Fa7dAcC660A9124c3685EE8a6E699d10409Eb',
533
533
  AaveV3SwapBorrowRateMode: '0x9d1D7A0dD5e82cCe9CC131eC0C807B0F543be70e',
534
534
  AaveV3Supply: '0x4Df428298a204E4881D95611320b30938CB3facd',
535
- AaveV3SetEMode: '0xdeF8B05Ce194D50C376233C9C5530027f6180442',
535
+ AaveV3SetEMode: '0xC2c66A380CC6CCb24B6C5f412905ce4f16c95D9b',
536
536
  AaveV3Payback: '0x1A8B4DF4DE4274630A5c5a8E42Fa5F0DdF654ec2',
537
537
  AaveV3CollateralSwitch: '0xFdfeA6469c537b19A334726E01621810bc49B929',
538
538
  AaveV3ClaimRewards: '0xCeB876C6A4dd76aFe645622db00D4E051D16dA66',
@@ -613,7 +613,7 @@ export const actionAddresses = {
613
613
  // Aave V3
614
614
  AaveV3Withdraw: '0xae56474aBe3C271579b513b6668864e39f65Ae15',
615
615
  AaveV3Supply: '0x7dFF34190d0307fC234fc7E8C152C9715083eB02',
616
- AaveV3SetEMode: '0xa2ABA81e65543d18dd1a1E4A31Bc41C4a86453cf',
616
+ AaveV3SetEMode: '0x40C9ce603923AACD0b7407Ff0EE844c9C067cEB7',
617
617
  AaveV3Payback: '0x125b8b832bd7f2ebd77eef148a6319ade751c44b',
618
618
  AaveV3CollateralSwitch: '0xa898078f369A78CE6b8023715e8f6d2Ad7d2719f',
619
619
  AaveV3ClaimRewards: '0x4839d021A24820e57C31D386d430e2e82694F73B',
@@ -647,7 +647,7 @@ export const actionAddresses = {
647
647
  // Aave V3
648
648
  AaveV3Withdraw: '0x4839d021A24820e57C31D386d430e2e82694F73B',
649
649
  AaveV3Supply: '0x9D95de57631DD8Ac071892843DA67FEe52EA3962',
650
- AaveV3SetEMode: '0xEDFc68e2874B0AFc0963e18AE4D68522aEc7f97D',
650
+ AaveV3SetEMode: '0xB0f1b62aaf819ca072868E1FC379A46457dFcea1',
651
651
  AaveV3Payback: '0xCd84Bff225760B6b8BAcF1e90e8409C25769EF52',
652
652
  AaveV3CollateralSwitch: '0xdDFFd19564F9703800Da8a2FB9c2b4a7242bf01F',
653
653
  AaveV3ClaimRewards: '0x50bCFC115283dF48Ab6382551B9B93b08E197747',
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@defisaver/sdk",
3
- "version": "1.3.38",
3
+ "version": "1.3.39",
4
4
  "description": "",
5
5
  "main": "./umd/index.js",
6
6
  "module": "./esm/src/index.js",
@@ -2,7 +2,7 @@ import { ActionWithL2 } from '../../ActionWithL2';
2
2
  import { getAddr } from '../../addresses';
3
3
  import { EthAddress, uint8 } from '../../types';
4
4
  /**
5
- * AaveV3SetEModeAction - Set EMode for the proxy AaveV3 position
5
+ * AaveV3SetEModeAction - Set EMode for an AaveV3 position
6
6
  *
7
7
  * @category AaveV3
8
8
  */
@@ -11,15 +11,22 @@ export class AaveV3SetEModeAction extends ActionWithL2 {
11
11
  * @param useOnDefaultMarket If this is true it defaults to the hardcoded market in contract
12
12
  * @param market Address provider for specific market
13
13
  * @param categoryId ID of the category emode
14
+ * @param onBehalf Address of the position owner, defaults to proxy
14
15
  */
15
- constructor(useOnDefaultMarket: boolean, market: EthAddress, categoryId: uint8) {
16
+ constructor(
17
+ useOnDefaultMarket: boolean,
18
+ market: EthAddress,
19
+ categoryId: uint8,
20
+ onBehalf: EthAddress = getAddr('Empty'),
21
+ ) {
16
22
  super('AaveV3SetEMode', getAddr('AaveV3SetEMode'),
17
- ['uint8', 'bool', 'address'],
18
- [categoryId, useOnDefaultMarket, market],
23
+ ['uint8', 'bool', 'address', 'address'],
24
+ [categoryId, useOnDefaultMarket, market, onBehalf],
19
25
  );
20
26
 
21
27
  this.mappableArgs = [
22
28
  this.args[2],
29
+ this.args[3],
23
30
  ];
24
31
  }
25
32
 
@@ -34,6 +41,8 @@ export class AaveV3SetEModeAction extends ActionWithL2 {
34
41
  // market
35
42
  encodedInput = encodedInput.concat(this.addressToBytes20(this.args[2]));
36
43
  }
44
+ // onBehalf
45
+ encodedInput = encodedInput.concat(this.addressToBytes20(this.args[3]));
37
46
 
38
47
  return encodedInput;
39
48
  }
package/src/addresses.ts CHANGED
@@ -89,7 +89,7 @@ export const actionAddresses = {
89
89
  AaveV3SwapBorrowRateMode:
90
90
  '0x630F530Ac523C935cf2528E62D0A06F8900C5b1B',
91
91
  AaveV3Supply: '0x91b3fCCEA2f2e0622Cc1fb54E12f5ac5aAa55a87',
92
- AaveV3SetEMode: '0xBe7F735d7955e0461579E34266f41F928AE06D78',
92
+ AaveV3SetEMode: '0x496C7Ed730E2692Fa49085aF2a9B61aCb0Bc1336',
93
93
  AaveV3Payback: '0xe29265217D65F5a2ae41972E09C13E107D049004',
94
94
  AaveV3CollateralSwitch: '0x54A4d6cB567B2C6CDe4687c361b24fd912695DAb',
95
95
  AaveV3ClaimRewards: '0x998A2E9aaE03c11b7A9863C1F59c42A21fcf47D0',
@@ -449,7 +449,7 @@ export const actionAddresses = {
449
449
  AaveV3Borrow: '0x8CaDc8A911D19B9e4D36c9bAdE47d970f362BcEa',
450
450
  AaveV3CollateralSwitch: '0x20D1388Ffa0A2D6ff6328AD014C67051542ca3a8',
451
451
  AaveV3Payback: '0x88eb4050e89FecE4DF940109B0e58daF9B59e551',
452
- AaveV3SetEMode: '0x7F264737066b9b7D9729Fe9715abB97423D8b35B',
452
+ AaveV3SetEMode: '0xf00eEB0Cb7e6c86319022B105f261C5666535c24',
453
453
  AaveV3Supply: '0x7e49bdf4690feef64cb341ca46d1e3b45233a683',
454
454
  AaveV3SwapBorrowRateMode:
455
455
  '0xB8f0243b492f0e80feF5315Ba8692e7635481845',
@@ -519,7 +519,7 @@ export const actionAddresses = {
519
519
  AaveV3Borrow: '0x5786809DA660dB613994460F096F19fcd19eD4c9',
520
520
  AaveV3CollateralSwitch: '0x7AcdD66C13f87b1cBcE7B106a8C34E426475BADd',
521
521
  AaveV3Payback: '0xd88D5356e08dAd84E1576F89f4BF43C79a8BF0b2',
522
- AaveV3SetEMode: '0x99D5068d9520316e8D3B5136c0B6EA33C5E0c27e',
522
+ AaveV3SetEMode: '0x112515e9040D853C2928F9ff21D12Ac920BD6Db9',
523
523
  AaveV3Supply: '0xA2127f5C7E943c05B6a6A3a541557087F1F1287D',
524
524
  AaveV3SwapBorrowRateMode:
525
525
  '0x738042389A8d6B0F6D6ab009c42dfF84ebB737C0',
@@ -638,7 +638,7 @@ export const actionAddresses = {
638
638
  AaveV3SwapBorrowRateMode:
639
639
  '0x9d1D7A0dD5e82cCe9CC131eC0C807B0F543be70e',
640
640
  AaveV3Supply: '0x4Df428298a204E4881D95611320b30938CB3facd',
641
- AaveV3SetEMode: '0xdeF8B05Ce194D50C376233C9C5530027f6180442',
641
+ AaveV3SetEMode: '0xC2c66A380CC6CCb24B6C5f412905ce4f16c95D9b',
642
642
  AaveV3Payback: '0x1A8B4DF4DE4274630A5c5a8E42Fa5F0DdF654ec2',
643
643
  AaveV3CollateralSwitch: '0xFdfeA6469c537b19A334726E01621810bc49B929',
644
644
  AaveV3ClaimRewards: '0xCeB876C6A4dd76aFe645622db00D4E051D16dA66',
@@ -732,7 +732,7 @@ export const actionAddresses = {
732
732
  // Aave V3
733
733
  AaveV3Withdraw: '0xae56474aBe3C271579b513b6668864e39f65Ae15',
734
734
  AaveV3Supply: '0x7dFF34190d0307fC234fc7E8C152C9715083eB02',
735
- AaveV3SetEMode: '0xa2ABA81e65543d18dd1a1E4A31Bc41C4a86453cf',
735
+ AaveV3SetEMode: '0x40C9ce603923AACD0b7407Ff0EE844c9C067cEB7',
736
736
  AaveV3Payback: '0x125b8b832bd7f2ebd77eef148a6319ade751c44b',
737
737
  AaveV3CollateralSwitch: '0xa898078f369A78CE6b8023715e8f6d2Ad7d2719f',
738
738
  AaveV3ClaimRewards: '0x4839d021A24820e57C31D386d430e2e82694F73B',
@@ -768,7 +768,7 @@ export const actionAddresses = {
768
768
  // Aave V3
769
769
  AaveV3Withdraw: '0x4839d021A24820e57C31D386d430e2e82694F73B',
770
770
  AaveV3Supply: '0x9D95de57631DD8Ac071892843DA67FEe52EA3962',
771
- AaveV3SetEMode: '0xEDFc68e2874B0AFc0963e18AE4D68522aEc7f97D',
771
+ AaveV3SetEMode: '0xB0f1b62aaf819ca072868E1FC379A46457dFcea1',
772
772
  AaveV3Payback: '0xCd84Bff225760B6b8BAcF1e90e8409C25769EF52',
773
773
  AaveV3CollateralSwitch: '0xdDFFd19564F9703800Da8a2FB9c2b4a7242bf01F',
774
774
  AaveV3ClaimRewards: '0x50bCFC115283dF48Ab6382551B9B93b08E197747',
@@ -0,0 +1,42 @@
1
+ const dfs = require('../../../src');
2
+ const { assert } = require('chai');
3
+ const { encodeForDsProxyCall, encodeForRecipe } = require('../../_actionUtils');
4
+
5
+ describe('Action: AaveV3SetEModeAction', () => {
6
+ const market = '0x24a42fD28C976A61Df5D00D0599C34c4f90748c8';
7
+ const onBehalf = '0x1111111111111111111111111111111111111111';
8
+ const categoryId = 1;
9
+
10
+ it('defaults onBehalf to the empty address', () => {
11
+ const action = new dfs.actions.aaveV3.AaveV3SetEModeAction(
12
+ true,
13
+ market,
14
+ categoryId,
15
+ );
16
+
17
+ assert.equal(action.args[3], dfs.getAddr('Empty'));
18
+ assert.deepEqual(action.mappableArgs, [market, dfs.getAddr('Empty')]);
19
+ assert.equal(
20
+ action.encodeInputs(),
21
+ `0x2895f3aa0101${dfs.getAddr('Empty').slice(2)}`,
22
+ );
23
+ });
24
+
25
+ it('encodes an explicit onBehalf after a custom market', () => {
26
+ const action = new dfs.actions.aaveV3.AaveV3SetEModeAction(
27
+ false,
28
+ market,
29
+ categoryId,
30
+ onBehalf,
31
+ );
32
+
33
+ assert.equal(action.args[3], onBehalf);
34
+ assert.deepEqual(action.mappableArgs, [market, onBehalf]);
35
+ assert.equal(
36
+ action.encodeInputs(),
37
+ `0x2895f3aa0100${market.slice(2)}${onBehalf.slice(2)}`,
38
+ );
39
+ encodeForDsProxyCall(action);
40
+ encodeForRecipe(action);
41
+ });
42
+ });
package/umd/index.js CHANGED
@@ -1397,7 +1397,7 @@ var actionAddresses = {
1397
1397
  AaveV3Withdraw: '0x9D4e4b26A5E2e6Dad30C5d95F5cE78A8310F04C2',
1398
1398
  AaveV3SwapBorrowRateMode: '0x630F530Ac523C935cf2528E62D0A06F8900C5b1B',
1399
1399
  AaveV3Supply: '0x91b3fCCEA2f2e0622Cc1fb54E12f5ac5aAa55a87',
1400
- AaveV3SetEMode: '0xBe7F735d7955e0461579E34266f41F928AE06D78',
1400
+ AaveV3SetEMode: '0x496C7Ed730E2692Fa49085aF2a9B61aCb0Bc1336',
1401
1401
  AaveV3Payback: '0xe29265217D65F5a2ae41972E09C13E107D049004',
1402
1402
  AaveV3CollateralSwitch: '0x54A4d6cB567B2C6CDe4687c361b24fd912695DAb',
1403
1403
  AaveV3ClaimRewards: '0x998A2E9aaE03c11b7A9863C1F59c42A21fcf47D0',
@@ -1695,7 +1695,7 @@ var actionAddresses = {
1695
1695
  AaveV3Borrow: '0x8CaDc8A911D19B9e4D36c9bAdE47d970f362BcEa',
1696
1696
  AaveV3CollateralSwitch: '0x20D1388Ffa0A2D6ff6328AD014C67051542ca3a8',
1697
1697
  AaveV3Payback: '0x88eb4050e89FecE4DF940109B0e58daF9B59e551',
1698
- AaveV3SetEMode: '0x7F264737066b9b7D9729Fe9715abB97423D8b35B',
1698
+ AaveV3SetEMode: '0xf00eEB0Cb7e6c86319022B105f261C5666535c24',
1699
1699
  AaveV3Supply: '0x7e49bdf4690feef64cb341ca46d1e3b45233a683',
1700
1700
  AaveV3SwapBorrowRateMode: '0xB8f0243b492f0e80feF5315Ba8692e7635481845',
1701
1701
  AaveV3Withdraw: '0xf19d045f6cFc04A5Ee5E0e8837b565b9f276e3F7',
@@ -1758,7 +1758,7 @@ var actionAddresses = {
1758
1758
  AaveV3Borrow: '0x5786809DA660dB613994460F096F19fcd19eD4c9',
1759
1759
  AaveV3CollateralSwitch: '0x7AcdD66C13f87b1cBcE7B106a8C34E426475BADd',
1760
1760
  AaveV3Payback: '0xd88D5356e08dAd84E1576F89f4BF43C79a8BF0b2',
1761
- AaveV3SetEMode: '0x99D5068d9520316e8D3B5136c0B6EA33C5E0c27e',
1761
+ AaveV3SetEMode: '0x112515e9040D853C2928F9ff21D12Ac920BD6Db9',
1762
1762
  AaveV3Supply: '0xA2127f5C7E943c05B6a6A3a541557087F1F1287D',
1763
1763
  AaveV3SwapBorrowRateMode: '0x738042389A8d6B0F6D6ab009c42dfF84ebB737C0',
1764
1764
  AaveV3Withdraw: '0xbf492F869DdB1A18BB4F41b6c3059D9f882Fe7ff',
@@ -1859,7 +1859,7 @@ var actionAddresses = {
1859
1859
  AaveV3Withdraw: '0x1d2Fa7dAcC660A9124c3685EE8a6E699d10409Eb',
1860
1860
  AaveV3SwapBorrowRateMode: '0x9d1D7A0dD5e82cCe9CC131eC0C807B0F543be70e',
1861
1861
  AaveV3Supply: '0x4Df428298a204E4881D95611320b30938CB3facd',
1862
- AaveV3SetEMode: '0xdeF8B05Ce194D50C376233C9C5530027f6180442',
1862
+ AaveV3SetEMode: '0xC2c66A380CC6CCb24B6C5f412905ce4f16c95D9b',
1863
1863
  AaveV3Payback: '0x1A8B4DF4DE4274630A5c5a8E42Fa5F0DdF654ec2',
1864
1864
  AaveV3CollateralSwitch: '0xFdfeA6469c537b19A334726E01621810bc49B929',
1865
1865
  AaveV3ClaimRewards: '0xCeB876C6A4dd76aFe645622db00D4E051D16dA66',
@@ -1941,7 +1941,7 @@ var actionAddresses = {
1941
1941
  // Aave V3
1942
1942
  AaveV3Withdraw: '0xae56474aBe3C271579b513b6668864e39f65Ae15',
1943
1943
  AaveV3Supply: '0x7dFF34190d0307fC234fc7E8C152C9715083eB02',
1944
- AaveV3SetEMode: '0xa2ABA81e65543d18dd1a1E4A31Bc41C4a86453cf',
1944
+ AaveV3SetEMode: '0x40C9ce603923AACD0b7407Ff0EE844c9C067cEB7',
1945
1945
  AaveV3Payback: '0x125b8b832bd7f2ebd77eef148a6319ade751c44b',
1946
1946
  AaveV3CollateralSwitch: '0xa898078f369A78CE6b8023715e8f6d2Ad7d2719f',
1947
1947
  AaveV3ClaimRewards: '0x4839d021A24820e57C31D386d430e2e82694F73B',
@@ -1975,7 +1975,7 @@ var actionAddresses = {
1975
1975
  // Aave V3
1976
1976
  AaveV3Withdraw: '0x4839d021A24820e57C31D386d430e2e82694F73B',
1977
1977
  AaveV3Supply: '0x9D95de57631DD8Ac071892843DA67FEe52EA3962',
1978
- AaveV3SetEMode: '0xEDFc68e2874B0AFc0963e18AE4D68522aEc7f97D',
1978
+ AaveV3SetEMode: '0xB0f1b62aaf819ca072868E1FC379A46457dFcea1',
1979
1979
  AaveV3Payback: '0xCd84Bff225760B6b8BAcF1e90e8409C25769EF52',
1980
1980
  AaveV3CollateralSwitch: '0xdDFFd19564F9703800Da8a2FB9c2b4a7242bf01F',
1981
1981
  AaveV3ClaimRewards: '0x50bCFC115283dF48Ab6382551B9B93b08E197747',
@@ -9889,7 +9889,7 @@ __webpack_require__.r(__webpack_exports__);
9889
9889
 
9890
9890
 
9891
9891
  /**
9892
- * AaveV3SetEModeAction - Set EMode for the proxy AaveV3 position
9892
+ * AaveV3SetEModeAction - Set EMode for an AaveV3 position
9893
9893
  *
9894
9894
  * @category AaveV3
9895
9895
  */
@@ -9898,10 +9898,12 @@ class AaveV3SetEModeAction extends _ActionWithL2__WEBPACK_IMPORTED_MODULE_0__.Ac
9898
9898
  * @param useOnDefaultMarket If this is true it defaults to the hardcoded market in contract
9899
9899
  * @param market Address provider for specific market
9900
9900
  * @param categoryId ID of the category emode
9901
+ * @param onBehalf Address of the position owner, defaults to proxy
9901
9902
  */
9902
9903
  constructor(useOnDefaultMarket, market, categoryId) {
9903
- super('AaveV3SetEMode', (0,_addresses__WEBPACK_IMPORTED_MODULE_1__.getAddr)('AaveV3SetEMode'), ['uint8', 'bool', 'address'], [categoryId, useOnDefaultMarket, market]);
9904
- this.mappableArgs = [this.args[2]];
9904
+ var onBehalf = arguments.length > 3 && arguments[3] !== undefined ? arguments[3] : (0,_addresses__WEBPACK_IMPORTED_MODULE_1__.getAddr)('Empty');
9905
+ super('AaveV3SetEMode', (0,_addresses__WEBPACK_IMPORTED_MODULE_1__.getAddr)('AaveV3SetEMode'), ['uint8', 'bool', 'address', 'address'], [categoryId, useOnDefaultMarket, market, onBehalf]);
9906
+ this.mappableArgs = [this.args[2], this.args[3]];
9905
9907
  }
9906
9908
  encodeInputs() {
9907
9909
  // executeActionDirectL2
@@ -9914,6 +9916,8 @@ class AaveV3SetEModeAction extends _ActionWithL2__WEBPACK_IMPORTED_MODULE_0__.Ac
9914
9916
  // market
9915
9917
  encodedInput = encodedInput.concat(this.addressToBytes20(this.args[2]));
9916
9918
  }
9919
+ // onBehalf
9920
+ encodedInput = encodedInput.concat(this.addressToBytes20(this.args[3]));
9917
9921
  return encodedInput;
9918
9922
  }
9919
9923
  }