Skip to content

Commit

Permalink
Merge pull request #23 from nemmtor/fix/prod-issue
Browse files Browse the repository at this point in the history
Fix/prod issue
  • Loading branch information
lennardevertz authored Jan 19, 2024
2 parents 73bc3b8 + 0e56cb5 commit 8a98921
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 8 deletions.
4 changes: 2 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@idriss-crypto/send-to-anyone-core",
"version": "0.4.7",
"version": "0.4.8",
"scripts": {
"build": "webpack",
"buildLocal": "webpack --watch --mode=none",
Expand All @@ -11,7 +11,7 @@
"@web3modal/ethers5": "^3.5.3",
"alchemy-sdk": "^2.0.2",
"fast-creator": "^1.6.0",
"idriss-crypto": "^1.9.1",
"idriss-crypto": "^1.9.2",
"web3": "^1.7.0"
},
"devDependencies": {
Expand Down
13 changes: 7 additions & 6 deletions src/sendToAnyoneLogic.js
Original file line number Diff line number Diff line change
Expand Up @@ -408,10 +408,9 @@ export const SendToAnyoneLogic = {
}

// exchanged for redundant multiple get accounts calls
const accounts = await this.web3.eth.getAccounts();
let selectedAccount = accounts[0];
const selectedAccount = await this.idriss.getConnectedAccount();

if (accounts.length > 0) {
if (selectedAccount) {
let result;

try {
Expand All @@ -424,6 +423,9 @@ export const SendToAnyoneLogic = {
console.log("post gas ", transactionOptions)
console.log(recipient, walletType, asset, message, transactionOptions);
console.log(network, this.idriss);
console.log({
recipient, walletType, asset, message, transactionOptions
})
result = await this.idriss.transferToIDriss(recipient, walletType, asset, message, transactionOptions);
} catch (err) {
console.log("error", err);
Expand Down Expand Up @@ -468,10 +470,9 @@ export const SendToAnyoneLogic = {
}

// exchanged for redundant multiple get accounts calls
const accounts = await this.web3.eth.getAccounts();
let selectedAccount = accounts[0];
const selectedAccount = this.idriss.getConnectedAccount();

if (accounts.length > 0) {
if (selectedAccount) {
let result;

try {
Expand Down

0 comments on commit 8a98921

Please sign in to comment.