Skip to content

Commit

Permalink
Update profile
Browse files Browse the repository at this point in the history
  • Loading branch information
ejMina226 committed May 7, 2024
1 parent 201e4f1 commit 15735d6
Show file tree
Hide file tree
Showing 3 changed files with 11 additions and 7 deletions.
6 changes: 4 additions & 2 deletions src/combined.ts
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,8 @@ export async function applyGenerator(
receiver,
parseInt(transactionInterval),
parseFloat(transactionAmount),
parseFloat(transactionFee));
parseFloat(transactionFee),
networkProfile);
}
else {
if (i % 2 === 0) {
Expand All @@ -50,7 +51,8 @@ export async function applyGenerator(
receiver,
parseInt(transactionInterval),
parseFloat(transactionAmount),
parseFloat(transactionFee)
parseFloat(transactionFee),
networkProfile
);
}
}
Expand Down
2 changes: 1 addition & 1 deletion src/entry.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@ program
.option('-t, --transaction-type <type>', 'transaction type (zkApp or regular)', 'regular')
.option('-a, --transaction-amount <amount>', 'amount of Mina to send', '2')
.option('-f, --transaction-fee <fee>', 'transaction fee', '0.1')
.option('-n, --network-profile', 'use network profile', 'testnet')
.option('-n, --network-profile <profile>', 'use network profile', 'testnet')
.action(async (options) => {
const url = options.url || process.env.MINA_GRAPHQL_URL;
const senderPrivateKey = options.senderPrivateKey || process.env.SENDER_PRIVATE_KEY;
Expand Down
10 changes: 6 additions & 4 deletions src/zkAppGenerator.ts
Original file line number Diff line number Diff line change
Expand Up @@ -12,11 +12,13 @@ export async function processZKTransaction(
receiver: string,
timeDelayMS: number,
amount: number,
fee: number
fee: number,
networkProfile: 'mainnet' | 'testnet'
) {
const devNet = Mina.Network(
network
);
const devNet = Mina.Network({
mina: network,
networkId: networkProfile
});
Mina.setActiveInstance(devNet);

let amountToSend = amount * 1000000000;
Expand Down

0 comments on commit 15735d6

Please sign in to comment.