diff --git a/client/src/hooks/useAccount.ts b/client/src/hooks/useAccount.ts index 418656cc5..ed1315699 100644 --- a/client/src/hooks/useAccount.ts +++ b/client/src/hooks/useAccount.ts @@ -57,22 +57,8 @@ const useAccount = () => { setTimeout(() => setIsPasting(false), 0); }; - const getChangedField = () => { - const changedField: Partial = {}; - - if (bankNameState.trim() !== '' && bankName !== bankNameState) { - changedField.bankName = bankNameState; - } - - if (accountNumberState.trim() !== '' && accountNumber !== accountNumberState) { - changedField.accountNumber = accountNumberState; - } - - return changedField; - }; - const enrollAccount = async () => { - await patchEventOutline(getChangedField()); + await patchEventOutline({bankName: bankNameState, accountNumber: accountNumberState}); }; useEffect(() => {