Skip to content

Commit

Permalink
Fix cypress tests
Browse files Browse the repository at this point in the history
  • Loading branch information
ThibautBremand committed Aug 31, 2023
1 parent eafb7b9 commit 28cf7f9
Showing 1 changed file with 0 additions and 6 deletions.
6 changes: 0 additions & 6 deletions packages/extension/src/hooks/useFees/useFees.ts
Original file line number Diff line number Diff line change
Expand Up @@ -27,8 +27,6 @@ export const useFees = (tx: Transaction | Transaction[], fee: string | null) =>
const transactions = Array.isArray(tx) ? tx : [tx];

if (transactions.length) {
const delay = (ms: number) => new Promise((resolve) => setTimeout(resolve, ms));

const processTransactions = async () => {
try {
const fees = [];
Expand All @@ -42,10 +40,6 @@ export const useFees = (tx: Transaction | Transaction[], fee: string | null) =>
? transaction.Fee
: await estimateNetworkFees(transaction);
fees.push(fee);

if (i < transactions.length - 1) {
await delay(10); // 10ms delay between each request
}
}
const totalFees = calculateTotalFees(fees);
setEstimatedFees(totalFees.toString());
Expand Down

0 comments on commit 28cf7f9

Please sign in to comment.