Skip to content

Commit

Permalink
Merge branch 'master' into dev/2.3.0
Browse files Browse the repository at this point in the history
  • Loading branch information
lovelycs committed Jul 17, 2019
2 parents 172f0a4 + 0604991 commit 85c54df
Show file tree
Hide file tree
Showing 23 changed files with 125 additions and 22 deletions.
2 changes: 1 addition & 1 deletion lerna.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
{
"version": "2.2.4",
"version": "2.2.6",
"packages": [
"src/*"
],
Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "@vite/vitejs",
"version": "2.2.4",
"version": "2.2.6",
"description": "",
"scripts": {
"format-type": "node build/type",
Expand Down
2 changes: 1 addition & 1 deletion src/HTTP/package.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"name":"@vite/vitejs-http","version":"2.2.4","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
{"name":"@vite/vitejs-http","version":"2.2.6","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
2 changes: 1 addition & 1 deletion src/IPC/package.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"name":"@vite/vitejs-ipc","version":"2.2.4","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
{"name":"@vite/vitejs-ipc","version":"2.2.6","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
2 changes: 1 addition & 1 deletion src/WS/package.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"name":"@vite/vitejs-ws","version":"2.2.4","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
{"name":"@vite/vitejs-ws","version":"2.2.6","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
15 changes: 15 additions & 0 deletions src/abi/coder/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -117,6 +117,21 @@ export function decodeParameters(types, params) {

types.forEach(type => {
const typeObj = formatType(type);

if (!typeObj.isDynamic && typeObj.isArr) {
let len = 0;
typeObj.arrLen.forEach(_l => {
len += _l * typeObj.byteLength;
});
const _p = _params.slice(0, len * 2);
_params = _params.slice(len * 2);
resArr.push({
isDynamic: false,
result: decodeArrs(typeObj, _p)
});
return;
}

if (!typeObj.isDynamic) {
const _res = decode[typeObj.type](typeObj, _params);
_params = _res.params;
Expand Down
2 changes: 1 addition & 1 deletion src/abi/package.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"name":"@vite/vitejs-abi","version":"2.2.4","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
{"name":"@vite/vitejs-abi","version":"2.2.6","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
2 changes: 1 addition & 1 deletion src/account/package.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"name":"@vite/vitejs-account","version":"2.2.4","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
{"name":"@vite/vitejs-account","version":"2.2.6","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
4 changes: 2 additions & 2 deletions src/accountBlock/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ const { getPublicKey, sign } = ed25519;

export const DefaultContractTxType = getContractTxType(Contracts);

export function getAccountBlock({ blockType, fromBlockHash, accountAddress, message, data, height, prevHash, toAddress, tokenId, amount, nonce }: syncFormatBlock) {
export function getAccountBlock({ blockType, fromBlockHash, accountAddress, message, data, height, prevHash, toAddress, tokenId, amount, nonce, fee }: syncFormatBlock) {
const reject = (error, errMsg = '') => {
const message = `${ error.message || '' } ${ errMsg }`;
throw new Error(message);
Expand All @@ -27,7 +27,7 @@ export function getAccountBlock({ blockType, fromBlockHash, accountAddress, mess
return reject(paramsFormat, 'No prevHash but height.');
}

return formatAccountBlock({ blockType, fromBlockHash, accountAddress, message, data, height, prevHash, toAddress, tokenId, amount, nonce });
return formatAccountBlock({ blockType, fromBlockHash, accountAddress, message, data, height, prevHash, toAddress, tokenId, amount, nonce, fee });
}

export function getSendTxBlock({ accountAddress, toAddress, tokenId, amount, message, data, height, prevHash }: sendTxBlock) {
Expand Down
2 changes: 1 addition & 1 deletion src/accountBlock/package.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"name":"@vite/vitejs-accountblock","version":"2.2.4","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
{"name":"@vite/vitejs-accountblock","version":"2.2.6","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
2 changes: 1 addition & 1 deletion src/addrAccount/package.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"name":"@vite/vitejs-addraccount","version":"2.2.4","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
{"name":"@vite/vitejs-addraccount","version":"2.2.6","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
2 changes: 1 addition & 1 deletion src/client/package.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"name":"@vite/vitejs-client","version":"2.2.4","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
{"name":"@vite/vitejs-client","version":"2.2.6","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
2 changes: 1 addition & 1 deletion src/communication/package.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"name":"@vite/vitejs-communication","version":"2.2.4","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
{"name":"@vite/vitejs-communication","version":"2.2.6","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
2 changes: 1 addition & 1 deletion src/constant/package.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"name":"@vite/vitejs-constant","version":"2.2.4","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
{"name":"@vite/vitejs-constant","version":"2.2.6","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
2 changes: 1 addition & 1 deletion src/error/package.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"name":"@vite/vitejs-error","version":"2.2.4","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
{"name":"@vite/vitejs-error","version":"2.2.6","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
2 changes: 1 addition & 1 deletion src/hdAccount/package.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"name":"@vite/vitejs-hdaccount","version":"2.2.4","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
{"name":"@vite/vitejs-hdaccount","version":"2.2.6","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
2 changes: 1 addition & 1 deletion src/hdAddr/package.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"name":"@vite/vitejs-hdaddr","version":"2.2.4","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
{"name":"@vite/vitejs-hdaddr","version":"2.2.6","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
2 changes: 1 addition & 1 deletion src/keystore/package.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"name":"@vite/vitejs-keystore","version":"2.2.4","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
{"name":"@vite/vitejs-keystore","version":"2.2.6","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
2 changes: 1 addition & 1 deletion src/netProcessor/package.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"name":"@vite/vitejs-netprocessor","version":"2.2.4","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
{"name":"@vite/vitejs-netprocessor","version":"2.2.6","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
2 changes: 1 addition & 1 deletion src/privToAddr/package.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"name":"@vite/vitejs-privtoaddr","version":"2.2.4","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
{"name":"@vite/vitejs-privtoaddr","version":"2.2.6","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
2 changes: 1 addition & 1 deletion src/utils/package.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"name":"@vite/vitejs-utils","version":"2.2.4","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
{"name":"@vite/vitejs-utils","version":"2.2.6","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"}}
2 changes: 1 addition & 1 deletion src/vitejs/package.json
Original file line number Diff line number Diff line change
@@ -1 +1 @@
{"name":"@vite/vitejs","version":"2.2.4","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"./distSrc/index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"},"dependencies":{"@sisi/ed25519-blake2b-hd-key":"^1.0.2","@sisi/tweetnacl-blake2b":"^1.0.0","babel-loader":"^8.0.4","bip39":"^2.5.0","blake2b":"^2.1.3","blakejs":"^1.1.0","bn.js":"^4.11.8","browserify-aes":"^1.2.0","buffer":"~5.2.1","commitizen":"^3.1.1","conventional-changelog-cli":"^2.0.21","create-hmac":"^1.1.7","es6-promise":"^4.2.5","jsonrpc-lite":"^2.0.3","lerna":"^3.13.1","net":"^1.0.2","pure-uuid":"^1.5.3","qs":"^6.6.0","scryptsy":"^2.0.0","ts-node":"^7.0.1","websocket":"^1.0.26","xhr2":"^0.1.4"}}
{"name":"@vite/vitejs","version":"2.2.6","main":"dist/index.node.js","browser":"dist/index.web.js","typings":"./distSrc/index.ts","repository":{"type":"git","url":"git+https://github.com/vitelabs/vite.js.git"},"license":"ISC","bugs":{"url":"https://github.com/vitelabs/vite.js/issues"},"homepage":"https://github.com/vitelabs/vite.js#readme","publishConfig":{"access":"public"},"dependencies":{"@sisi/ed25519-blake2b-hd-key":"^1.0.2","@sisi/tweetnacl-blake2b":"^1.0.0","babel-loader":"^8.0.4","bip39":"^2.5.0","blake2b":"^2.1.3","blakejs":"^1.1.0","bn.js":"^4.11.8","browserify-aes":"^1.2.0","buffer":"~5.2.1","commitizen":"^3.1.1","conventional-changelog-cli":"^2.0.21","create-hmac":"^1.1.7","es6-promise":"^4.2.5","jsonrpc-lite":"^2.0.3","lerna":"^3.13.1","net":"^1.0.2","pure-uuid":"^1.5.3","qs":"^6.6.0","scryptsy":"^2.0.0","ts-node":"^7.0.1","websocket":"^1.0.26","xhr2":"^0.1.4"}}
Loading

0 comments on commit 85c54df

Please sign in to comment.