@@ -7,8 +7,6 @@ import { Row, Col, H1 } from '../components/Base'
77import { ROUTE_NAMES } from '../lib/router'
88import { EthereumWallet } from '../lib/wallet'
99
10−const secre = /[0-9A-Fa-f]{64}/g
11−
1210class PrivateKey extends React.Component {
1311
1412 constructor(props) {
@@ -28,7 +26,7 @@ class PrivateKey extends React.Component {
2826
2927 constructWallet(privateKey) {
3028 const { setWallet } = this.props
31− if (secre.test(privateKey) === true) {
29+ if (/^[0-9A-Fa-f]{64}$/g.test(privateKey) === true) {
3230 const sec = Buffer.from(privateKey, 'hex')
3331 const wallet = new EthereumWallet(sec)
3432 setWallet(Maybe.Just(wallet))