Wallet subscriptions & refresh (#7283)

* Update to @parity/api 2.1.7

* Update packages

* Update after signer API alias
This commit is contained in:
Jaco Greeff 2017-12-15 12:48:51 +01:00 committed by GitHub
parent 9821fd92e4
commit 6587dfecc0
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
6 changed files with 19 additions and 51 deletions

View File

@ -15,9 +15,9 @@
}
},
"@parity/api": {
"version": "2.1.5",
"resolved": "https://registry.npmjs.org/@parity/api/-/api-2.1.5.tgz",
"integrity": "sha512-HkvMIhIwDMEIyTmXqEjWn1C2qes0qJO270bQldRfCZf0XiOGXG726EzV3FUpUbVONCVQ9riDviAl3fw6D+N6nA==",
"version": "2.1.14",
"resolved": "https://registry.npmjs.org/@parity/api/-/api-2.1.14.tgz",
"integrity": "sha512-1IiaXJCXkhNUNeWiMcLKrdXcPnLjdH58zIc8zk4IgwFvJ3ZNriV1W6lGHghHB9GbNcHgpZdpYt4NUvu67oWZ9w==",
"requires": {
"@parity/abi": "2.1.2",
"@parity/jsonrpc": "2.1.4",
@ -3416,11 +3416,6 @@
"randomfill": "1.0.3"
}
},
"crypto-js": {
"version": "3.1.8",
"resolved": "https://registry.npmjs.org/crypto-js/-/crypto-js-3.1.8.tgz",
"integrity": "sha1-cV8HC/YBTyrpkqmLOSkli3E/CNU="
},
"css-color-names": {
"version": "0.0.4",
"resolved": "https://registry.npmjs.org/css-color-names/-/css-color-names-0.0.4.tgz",
@ -13475,22 +13470,6 @@
}
}
},
"web3": {
"version": "0.17.0-beta",
"resolved": "https://registry.npmjs.org/web3/-/web3-0.17.0-beta.tgz",
"integrity": "sha1-V684JFv/ejIJn3zleA+tW7wA2ls=",
"requires": {
"bignumber.js": "git+https://github.com/debris/bignumber.js.git#94d7146671b9719e00a09c29b01a691bc85048c2",
"crypto-js": "3.1.8",
"utf8": "2.1.2",
"xmlhttprequest": "1.8.0"
},
"dependencies": {
"bignumber.js": {
"version": "git+https://github.com/debris/bignumber.js.git#94d7146671b9719e00a09c29b01a691bc85048c2"
}
}
},
"webidl-conversions": {
"version": "4.0.2",
"resolved": "https://registry.npmjs.org/webidl-conversions/-/webidl-conversions-4.0.2.tgz",
@ -13794,11 +13773,6 @@
"integrity": "sha1-TYuPHszTQZqjYgYb7O9RXh5VljU=",
"dev": true
},
"xmlhttprequest": {
"version": "1.8.0",
"resolved": "https://registry.npmjs.org/xmlhttprequest/-/xmlhttprequest-1.8.0.tgz",
"integrity": "sha1-Z/4HXFwk/vOfnWX197f+dRcZaPw="
},
"xss-filters": {
"version": "1.2.7",
"resolved": "https://registry.npmjs.org/xss-filters/-/xss-filters-1.2.7.tgz",

View File

@ -31,7 +31,7 @@
"build:app": "webpack --config webpack/app",
"build:dll": "webpack --config webpack/vendor",
"ci:build": "cross-env NODE_ENV=production npm run build",
"clean": "rimraf ./.build ./.coverage ./.happypack ./.npmjs ./build ./node_modules/.cache",
"clean": "rimraf ./.build ./.coverage ./.happypack ./.npmjs ./node_modules/.cache",
"lint": "npm run lint:css && npm run lint:js",
"lint:css": "stylelint ./src/**/*.css",
"lint:js": "eslint --ignore-path .gitignore ./src/",
@ -133,7 +133,7 @@
},
"dependencies": {
"@parity/abi": "2.1.x",
"@parity/api": "2.1.x",
"@parity/api": "^2.1.14",
"@parity/wordlist": "1.1.x",
"base32.js": "0.1.0",
"bignumber.js": "3.0.1",

View File

@ -33,7 +33,6 @@
<div id="container">
<div class="loading">Loading</div>
</div>
<script src="/parity-utils/inject.js"></script>
<script src="vendor.js"></script>
</body>
</html>

18
js/package-lock.json generated
View File

@ -15,9 +15,9 @@
}
},
"@parity/api": {
"version": "2.1.6",
"resolved": "https://registry.npmjs.org/@parity/api/-/api-2.1.6.tgz",
"integrity": "sha512-4HuUJLGkZEAHSy5918ofepKXWvAE89VsoUN7q1Px9ASN8xLR3MWPMuNxOJZjKTqVDZWpXs8q3g7GIOVdi90BXA==",
"version": "2.1.14",
"resolved": "https://registry.npmjs.org/@parity/api/-/api-2.1.14.tgz",
"integrity": "sha512-1IiaXJCXkhNUNeWiMcLKrdXcPnLjdH58zIc8zk4IgwFvJ3ZNriV1W6lGHghHB9GbNcHgpZdpYt4NUvu67oWZ9w==",
"requires": {
"@parity/abi": "2.1.2",
"@parity/jsonrpc": "2.1.4",
@ -52,7 +52,7 @@
"version": "github:js-dist-paritytech/dapp-dapp-methods#7245089a8e83274372cde3c9406ae155e2083f84",
"dev": true,
"requires": {
"@parity/api": "2.1.6",
"@parity/api": "2.1.14",
"@parity/shared": "2.2.14",
"@parity/ui": "2.2.15",
"lodash": "4.17.4",
@ -74,7 +74,7 @@
"integrity": "sha512-6bICFA1c1GBz4d7vratkoqovBezJNjc8VCwnZtpPTcyLeMshAhatPV4dGgJo/eHtlOCkKAeaAKatWZhEtXt/5g==",
"dev": true,
"requires": {
"@parity/api": "2.1.6",
"@parity/api": "2.1.14",
"@parity/etherscan": "2.1.3",
"@parity/shared": "2.2.14",
"bignumber.js": "3.0.1",
@ -556,7 +556,7 @@
"version": "github:js-dist-paritytech/dapp-dapp-visible#84f40feb42f1707d7f463213a990600dc11978f7",
"dev": true,
"requires": {
"@parity/api": "2.1.6",
"@parity/api": "2.1.14",
"@parity/ui": "2.2.15",
"mobx": "3.3.2",
"mobx-react": "4.3.5",
@ -576,7 +576,7 @@
"integrity": "sha512-6bICFA1c1GBz4d7vratkoqovBezJNjc8VCwnZtpPTcyLeMshAhatPV4dGgJo/eHtlOCkKAeaAKatWZhEtXt/5g==",
"dev": true,
"requires": {
"@parity/api": "2.1.6",
"@parity/api": "2.1.14",
"@parity/etherscan": "2.1.3",
"@parity/shared": "2.2.14",
"bignumber.js": "3.0.1",
@ -1103,7 +1103,7 @@
"resolved": "https://registry.npmjs.org/@parity/etherscan/-/etherscan-2.1.3.tgz",
"integrity": "sha512-GtQMaE8t7PDOcz/K4Ud+Z6EELB47+qG5V6R7iTJ4DcueXVgiMAXK5OiNeKF3Qjd1/M4FIJdFm5NTSdC7bR38+Q==",
"requires": {
"@parity/api": "2.1.6",
"@parity/api": "2.1.14",
"bignumber.js": "3.0.1",
"es6-promise": "4.1.1",
"node-fetch": "1.7.3",
@ -1202,7 +1202,7 @@
"resolved": "https://registry.npmjs.org/@parity/ui/-/ui-3.0.16.tgz",
"integrity": "sha512-yGQ8k2/oNxu0GyJ6eQS1AUk1O1XR//oXfaHPEBa0VuJIB7gY9lPrkG7CSNpazOrTCfhdCHgpjGe3WR5lbv0HiQ==",
"requires": {
"@parity/api": "2.1.6",
"@parity/api": "2.1.14",
"@parity/etherscan": "2.1.3",
"@parity/shared": "2.2.14",
"babel-runtime": "6.26.0",

View File

@ -27,7 +27,7 @@
"build:embed": "cross-env EMBED=1 node webpack/embed",
"build:i18n": "npm run clean && npm run build && babel-node ./scripts/build-i18n.js",
"ci:build": "cross-env NODE_ENV=production npm run build",
"clean": "rimraf ./.build ./.coverage ./.happypack ./build",
"clean": "rimraf ./.build ./.coverage ./.happypack",
"coveralls": "npm run testCoverage && coveralls < coverage/lcov.info",
"lint": "npm run lint:css && npm run lint:js",
"lint:cached": "npm run lint:css && npm run lint:js:cached",
@ -140,7 +140,7 @@
"yargs": "6.6.0"
},
"dependencies": {
"@parity/api": "^2.1.6",
"@parity/api": "^2.1.14",
"@parity/plugin-signer-account": "paritytech/plugin-signer-account",
"@parity/plugin-signer-default": "paritytech/plugin-signer-default",
"@parity/plugin-signer-hardware": "paritytech/plugin-signer-hardware",

View File

@ -242,14 +242,9 @@ export default class Store {
return;
}
if (
(method &&
methodGroupFromMethod[method] &&
!this.hasTokenPermission(method, token)) ||
(api &&
methodGroupFromMethod[params[0]] &&
!this.hasTokenPermission(method, token))
) {
const _method = api ? params[0] : method;
if (methodGroupFromMethod[_method] && !this.hasTokenPermission(_method, token)) {
this.queueRequest(id, { // The requestId of a request is the id inside data
data,
source