Skip to content

Commit

Permalink
remove SC param from file init costs
Browse files Browse the repository at this point in the history
  • Loading branch information
phoebe committed Jan 22, 2025
1 parent a05b530 commit 08c8d9a
Showing 1 changed file with 2 additions and 5 deletions.
7 changes: 2 additions & 5 deletions cli/src/lib/website/filesInit.ts
Original file line number Diff line number Diff line change
Expand Up @@ -121,7 +121,7 @@ export async function sendFilesInits(
const operations: Operation[] = []

for (const batch of batches) {
const coins = await batch.batchCost(sc)
const coins = await batch.batchCost()
const gas = await batch.estimateGas(sc)
const args = batch.serialize()

Expand Down Expand Up @@ -229,7 +229,6 @@ export async function prepareCost(
}

export async function filesInitCost(
_sc: SmartContract,
files: FileInit[],
filesToDelete: FileDelete[],
metadatas: Metadata[],
Expand Down Expand Up @@ -271,7 +270,6 @@ async function estimatePrepareGas(
metadatasToDelete: Metadata[]
): Promise<bigint> {
const coins = await filesInitCost(
sc,
files,
filesToDelete,
metadatas,
Expand Down Expand Up @@ -327,9 +325,8 @@ class Batch {
.serialize()
}

batchCost(sc: SmartContract): Promise<bigint> {
batchCost(): Promise<bigint> {
return filesInitCost(
sc,
this.fileInits,
this.fileDeletes,
this.metadatas,
Expand Down

0 comments on commit 08c8d9a

Please sign in to comment.