Skip to content

Commit e0695fc

Browse files
committed
feat: remove roles autofilling when creating vault
1 parent ad4945f commit e0695fc

1 file changed

Lines changed: 1 addition & 11 deletions

File tree

  • features/create-vault/create-vault-form

features/create-vault/create-vault-form/utils.ts

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,6 @@ import { encodeFunctionData, parseEventLogs } from 'viem';
33
import { VaultFactoryAbi } from 'abi/vault-factory';
44
import {
55
VAULT_TOTAL_BASIS_POINTS,
6-
VAULTS_OWNER_ROLES_MAP,
76
VAULTS_CONNECT_DEPOSIT,
87
} from 'modules/vaults';
98

@@ -27,15 +26,6 @@ export const schemaToTx = (unparsedValues: CreateVaultSchema) => {
2726
// first manager goes to factory as direct argument
2827
const [defaultAdmin] = values.vaultManager;
2928

30-
// For now we populate all VaultManagers to all their roles
31-
// will be changed for next contract version
32-
const roles = Object.values(VAULTS_OWNER_ROLES_MAP).flatMap((role) => {
33-
return values.vaultManager.map((admin) => ({
34-
role,
35-
account: admin.value,
36-
}));
37-
});
38-
3929
return {
4030
data: encodeFunctionData({
4131
abi: VaultFactoryAbi,
@@ -46,7 +36,7 @@ export const schemaToTx = (unparsedValues: CreateVaultSchema) => {
4636
nodeOperatorManager,
4737
nodeOperatorFeeBPFormatted,
4838
confirmExpiryFormatted,
49-
roles,
39+
[],
5040
],
5141
}),
5242
value: VAULTS_CONNECT_DEPOSIT,

0 commit comments

Comments
 (0)