Skip to content

Commit

Permalink
refactor: remove approverFunds and serviceProviderFunds setters from …
Browse files Browse the repository at this point in the history
…Escrow interface and slice
  • Loading branch information
JoelVR17 committed Feb 19, 2025
1 parent ae207bd commit cea24bb
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 16 deletions.
7 changes: 0 additions & 7 deletions src/core/store/data/@types/escrows.entity.ts
Original file line number Diff line number Diff line change
Expand Up @@ -10,12 +10,8 @@ export interface EscrowGlobalStore {
escrowsToDelete: string[];
userRolesInEscrow: string[];
recentEscrow: Escrow | undefined;
approverFunds: string;
serviceProviderFunds: string;

setEscrows: (escrows: Escrow[]) => void;
setSelectedEscrow: (selectedEscrow?: Escrow) => void;
// setEscrowsToDelete: (escrows: string[]) => void;
fetchAllEscrows: (params: { address: string; type: string }) => void;
addEscrow: (
payload: EscrowPayload,
Expand All @@ -28,7 +24,4 @@ export interface EscrowGlobalStore {
}) => Promise<Escrow | undefined>;
setUserRolesInEscrow: (roles: string[]) => void;
setRecentEscrow: (escrow: Escrow | undefined) => void;
setApproverFunds: (approverFunds: string) => void;
setServiceProviderFunds: (serviceProviderFunds: string) => void;
// deleteProduct: (escrowId: strin`g) => void;
}
10 changes: 1 addition & 9 deletions src/core/store/data/slices/escrows.slice.ts
Original file line number Diff line number Diff line change
Expand Up @@ -44,7 +44,7 @@ export const useGlobalEscrowsSlice: StateCreator<
setEscrows: (escrows: Escrow[]) =>
set({ escrows }, false, ESCROW_ACTIONS.SET_ESCROWS),

setSelectedEscrow: (escrow) =>
setSelectedEscrow: (escrow: Escrow) =>
set(
{ selectedEscrow: escrow },
false,
Expand Down Expand Up @@ -156,13 +156,5 @@ export const useGlobalEscrowsSlice: StateCreator<
setRecentEscrow: (escrow: Escrow | undefined) => {
set({ recentEscrow: escrow });
},

setApproverFunds: (approverFunds: string) => {
set({ approverFunds });
},

setServiceProviderFunds: (serviceProviderFunds: string) => {
set({ serviceProviderFunds });
},
};
};

0 comments on commit cea24bb

Please sign in to comment.