Skip to content
This repository has been archived by the owner on Dec 19, 2020. It is now read-only.

Commit

Permalink
fix tx sign popup, remove debuggers
Browse files Browse the repository at this point in the history
  • Loading branch information
vbloher committed Dec 6, 2018
1 parent de500e9 commit 3c0f2bb
Showing 1 changed file with 3 additions and 6 deletions.
9 changes: 3 additions & 6 deletions src/redux/wallet.js
Original file line number Diff line number Diff line change
Expand Up @@ -327,8 +327,6 @@ export const approve = (gasLimit, gasPrice) => (dispatch, getState) => {
web3Reqest.params[0].gasPrice = web3.utils.numberToHex(+gasPrice);
}

debugger

provider.sendAsync(web3Reqest, (e, result) => {
if (!wv) {
return;
Expand All @@ -353,14 +351,14 @@ export const approve = (gasLimit, gasPrice) => (dispatch, getState) => {
const showAndCaclulateSingPopup = (payload) => (dispatch, getState) => {
web3Reqest = payload;

dispatch(hideTxError());

const params = payload.params[0];
const initialGasPrice = params.gasPrice ? web3.utils.fromWei(params.gasPrice, 'Gwei') : 0;

let gasPricePromise = Promise.resolve(initialGasPrice);
let gasLimitPromise = Promise.resolve(params.gas);

debugger

if (!params.gasPrice) {
gasPricePromise = new Promise((resolve) => {
web3.eth.getGasPrice((error, value) => {
Expand Down Expand Up @@ -586,7 +584,7 @@ const saveTransaction = (payload, txHash) => {

export const getTransactions = (address) => (dispatch) => {
if (!address) return;

const _address = address.toLowerCase();
const jsonStr = localStorage.getItem('transactions' + _address) || '[]';
const transactions = JSON.parse(jsonStr);
Expand All @@ -600,7 +598,6 @@ export const getTransactions = (address) => (dispatch) => {


export const resend = (txHash) => (dispatch, getState) => {
debugger
const address = getState().wallet.defaultAccount;
if (!address || !txHash) return;

Expand Down

0 comments on commit 3c0f2bb

Please sign in to comment.