Skip to content

Commit

Permalink
rm debug traces
Browse files Browse the repository at this point in the history
  • Loading branch information
quasisamurai committed Sep 19, 2024
1 parent 5e516f8 commit f1147a4
Showing 1 changed file with 14 additions and 21 deletions.
35 changes: 14 additions & 21 deletions src/helpers/signing_neutron_client.ts
Original file line number Diff line number Diff line change
Expand Up @@ -98,27 +98,20 @@ export class SigningNeutronClient extends CosmWasmClient {
fee: StdFee | 'auto' | number = 'auto',
admin: string = this.sender,
): Promise<string> {
try {
// Upload
const wasmCode = await this.getNeutronContract(fileName);
const uploadResult = await this.client.upload(this.sender, wasmCode, fee);
console.log('Upload logs:', uploadResult.logs);

// Instantiate
const res = await this.client.instantiate(
this.sender,
uploadResult.codeId,
msg,
label,
fee,
{ admin },
);
console.log('Instantiation events:', res.events);
return res.contractAddress;
} catch (error) {
console.error('Error during contract upload/instantiation:', error);
throw new Error(`Contract instantiation failed: ${error}`);
}
// upload
const wasmCode = await this.getNeutronContract(fileName);
const uploadResult = await this.client.upload(this.sender, wasmCode, fee);

// instantiate
const res = await this.client.instantiate(
this.sender,
uploadResult.codeId,
msg,
label,
fee,
{ admin },
);
return res.contractAddress;
}

async migrate(
Expand Down

0 comments on commit f1147a4

Please sign in to comment.