From 69b08ccb8f4952c6f745373cf06663819bb6b05d Mon Sep 17 00:00:00 2001 From: Shivam Chaudhary Date: Tue, 7 Feb 2023 11:36:50 +0100 Subject: [PATCH] Modify function's name and parameter --- src/withdrawMoney.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/withdrawMoney.c b/src/withdrawMoney.c index 52c8c45..6361124 100644 --- a/src/withdrawMoney.c +++ b/src/withdrawMoney.c @@ -2,7 +2,7 @@ #include "currentCustomerAccountBalance.c" #include "updateCustomerAccountBalance.c" -void notifyCustomer(amountToWithdraw, remainingAccountBalance) { +void notifyCustomer(float amountToWithdraw, float remainingAccountBalance) { char returnToHomeInput; printf("You have successfully withdrawn %f €.\n", amountToWithdraw); @@ -34,7 +34,7 @@ void withdraw(int user_id) { if (amountToWithdraw > 0) { if (amountToWithdraw <= availableAccountBalance) { remainingAccountBalance = initiateWithdraw(amountToWithdraw, availableAccountBalance); - updateSuccess = updateAccountBalance(user_id, remainingAccountBalance); + updateSuccess = updateAvailableAccountBalance(user_id, remainingAccountBalance); if( updateSuccess ) { notifyCustomer(amountToWithdraw, remainingAccountBalance); }