throw new IllegalArgumentException(
format("transfer amount must be at least $%.2f", minimumTransferAmount));
TransferReceipt receipt = new TransferReceipt();
Account srcAcct = accountRepository.findById(srcAcctId);
Account dstAcct = accountRepository.findById(dstAcctId);
receipt.setInitialSourceAccount(srcAcct);
receipt.setInitialDestinationAccount(dstAcct);
double fee = feePolicy.calculateFee(amount);
if (fee > 0)
srcAcct.debit(fee);
receipt.setTransferAmount(amount);
receipt.setFeeAmount(fee);
srcAcct.debit(amount);
dstAcct.credit(amount);
accountRepository.updateBalance(srcAcct);
accountRepository.updateBalance(dstAcct);
receipt.setFinalSourceAccount(srcAcct);