Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Updated the type used to create the LocalWallet in the admin_calls #1

Merged
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Updated the type used to create the LocalWallet in the admin_calls
MauricinhoMorales committed Feb 27, 2023

Verified

This commit was signed with the committer’s verified signature.
bsherman Benjamin Sherman
commit 958065fe18ca8208208b27fd2886494d487d0990
20 changes: 10 additions & 10 deletions src/admin_calls.rs
Original file line number Diff line number Diff line change
@@ -22,7 +22,7 @@ pub async fn total_supply() -> Result<TotalSupplyOutput> {

let provider = GOERLI.provider();

let wallet: LocalWallet = env.private_key.parse()?;
let wallet: LocalWallet = env.private_key.as_str().parse()?;
let wallet = wallet.with_chain_id(CHAIN_ID);

let client = SignerMiddleware::new(provider, wallet);
@@ -44,7 +44,7 @@ pub async fn contract_type() -> Result<ContractTypeOutput> {

let provider = GOERLI.provider();

let wallet: LocalWallet = env.private_key.parse()?;
let wallet: LocalWallet = env.private_key.as_str().parse()?;
let wallet = wallet.with_chain_id(CHAIN_ID);

let client = SignerMiddleware::new(provider, wallet);
@@ -69,7 +69,7 @@ pub async fn allowance(owner_address: &str, spender_address: &str) -> Result<All

let provider = GOERLI.provider();

let wallet: LocalWallet = env.private_key.parse()?;
let wallet: LocalWallet = env.private_key.as_str().parse()?;
let wallet = wallet.with_chain_id(CHAIN_ID);

let client = SignerMiddleware::new(provider, wallet);
@@ -98,7 +98,7 @@ pub async fn name() -> Result<NameOutput> {

let provider = GOERLI.provider();

let wallet: LocalWallet = env.private_key.parse()?;
let wallet: LocalWallet = env.private_key.as_str().parse()?;
let wallet = wallet.with_chain_id(CHAIN_ID);

let client = SignerMiddleware::new(provider, wallet);
@@ -118,7 +118,7 @@ pub async fn symbol() -> Result<SymbolOutput> {

let provider = GOERLI.provider();

let wallet: LocalWallet = env.private_key.parse()?;
let wallet: LocalWallet = env.private_key.as_str().parse()?;
let wallet = wallet.with_chain_id(CHAIN_ID);

let client = SignerMiddleware::new(provider, wallet);
@@ -139,7 +139,7 @@ pub async fn mint_to(account_address: &str, amount: U256) -> Result<ReceiptOutpu

let provider = GOERLI.provider();

let wallet: LocalWallet = env.private_key.parse()?;
let wallet: LocalWallet = env.private_key.as_str().parse()?;
let wallet = wallet.with_chain_id(CHAIN_ID);

let client = SignerMiddleware::new(provider, wallet);
@@ -168,7 +168,7 @@ pub async fn increase_allowance(spender_address: &str, amount: U256) -> Result<R

let provider = GOERLI.provider();

let wallet: LocalWallet = env.private_key.parse()?;
let wallet: LocalWallet = env.private_key.as_str().parse()?;
let wallet = wallet.with_chain_id(CHAIN_ID);

let client = SignerMiddleware::new(provider, wallet);
@@ -199,7 +199,7 @@ pub async fn decrease_allowance(spender_address: &str, amount: U256) -> Result<R

let provider = GOERLI.provider();

let wallet: LocalWallet = env.private_key.parse()?;
let wallet: LocalWallet = env.private_key.as_str().parse()?;
let wallet = wallet.with_chain_id(CHAIN_ID);

let client = SignerMiddleware::new(provider, wallet);
@@ -230,7 +230,7 @@ pub async fn burn_from(account_address: &str, amount: U256) -> Result<ReceiptOut

let provider = GOERLI.provider();

let wallet: LocalWallet = env.private_key.parse()?;
let wallet: LocalWallet = env.private_key.as_str().parse()?;
let wallet = wallet.with_chain_id(CHAIN_ID);

let client = SignerMiddleware::new(provider, wallet);
@@ -259,7 +259,7 @@ pub async fn transfer(account_address: &str, amount: U256) -> Result<ReceiptOutp

let provider = GOERLI.provider();

let wallet: LocalWallet = env.private_key.parse()?;
let wallet: LocalWallet = env.private_key.as_str().parse()?;
let wallet = wallet.with_chain_id(CHAIN_ID);

let client = SignerMiddleware::new(provider, wallet);