Merge branch 'master' into securityMessage

pull/5370/head
Aniket 2 years ago committed by GitHub
commit 69bde84579
  1. 2
      apps/remix-ide/src/blockchain/execution-context.js
  2. 3
      libs/remix-ui/debugger-ui/src/lib/vm-debugger/global-variables.tsx
  3. 2
      package.json
  4. 677
      yarn.lock

@ -156,7 +156,7 @@ export class ExecutionContext {
return cb()
} else {
if (injectedProvider && injectedProvider._metamask && injectedProvider._metamask.isUnlocked) {
if (!await injectedProvider._metamask.isUnlocked()) this.call('notification', 'toast', 'Please make sure the injected provider is unlocked (e.g Metamask).')
if (!await injectedProvider._metamask.isUnlocked()) infoCb('Please make sure the injected provider is unlocked (e.g Metamask).')
}
this.askPermission()
this.executionContext = context

@ -1,6 +1,7 @@
import React from 'react' // eslint-disable-line
import DropdownPanel from './dropdown-panel' // eslint-disable-line
import { BN } from 'ethereumjs-util'
import Web3 from 'web3'
export const GlobalVariables = ({ block, receipt, tx }) => {
// see https://docs.soliditylang.org/en/latest/units-and-global-variables.html#block-and-transaction-properties
@ -17,7 +18,7 @@ export const GlobalVariables = ({ block, receipt, tx }) => {
'tx.origin': tx.from
}
if (block.baseFeePerGas) {
globals['block.basefee'] = (new BN(block.baseFeePerGas.replace('0x', ''), 'hex')).toString(10) + ` Wei (${block.baseFeePerGas})`
globals['block.basefee'] = Web3.utils.toBN(block.baseFeePerGas).toString(10) + ` Wei (${block.baseFeePerGas})`
}
return (

@ -211,7 +211,7 @@
"time-stamp": "^2.2.0",
"ts-loader": "^9.2.6",
"tslib": "^2.3.0",
"web3": "^1.5.1",
"web3": "^1.7.5",
"winston": "^3.3.3",
"ws": "^7.3.0"
},

File diff suppressed because it is too large Load Diff
Loading…
Cancel
Save