aboutsummaryrefslogtreecommitdiffstats
path: root/packages/web3-wrapper
diff options
context:
space:
mode:
authorfragosti <francesco.agosti93@gmail.com>2018-06-20 04:29:54 +0800
committerfragosti <francesco.agosti93@gmail.com>2018-06-20 04:29:54 +0800
commita75d6531f207aac8aeefa94bb44fa96a5b295998 (patch)
treefc1c581f4c35e188b0a16461936b8d0e3323bfe6 /packages/web3-wrapper
parentbdd299dd9ee4699ccf5a4ab648e721e03ab2a139 (diff)
parentda69ddc19b29cfca05d28084b196324e121987ea (diff)
downloaddexon-sol-tools-a75d6531f207aac8aeefa94bb44fa96a5b295998.tar
dexon-sol-tools-a75d6531f207aac8aeefa94bb44fa96a5b295998.tar.gz
dexon-sol-tools-a75d6531f207aac8aeefa94bb44fa96a5b295998.tar.bz2
dexon-sol-tools-a75d6531f207aac8aeefa94bb44fa96a5b295998.tar.lz
dexon-sol-tools-a75d6531f207aac8aeefa94bb44fa96a5b295998.tar.xz
dexon-sol-tools-a75d6531f207aac8aeefa94bb44fa96a5b295998.tar.zst
dexon-sol-tools-a75d6531f207aac8aeefa94bb44fa96a5b295998.zip
Merge branch 'v2-prototype' of https://github.com/0xProject/0x-monorepo into bug/website/onboarding-improvements
Diffstat (limited to 'packages/web3-wrapper')
-rw-r--r--packages/web3-wrapper/CHANGELOG.json10
-rw-r--r--packages/web3-wrapper/CHANGELOG.md10
-rw-r--r--packages/web3-wrapper/package.json12
-rw-r--r--packages/web3-wrapper/src/web3_wrapper.ts9
4 files changed, 32 insertions, 9 deletions
diff --git a/packages/web3-wrapper/CHANGELOG.json b/packages/web3-wrapper/CHANGELOG.json
index bd4bf06dd..624ad7151 100644
--- a/packages/web3-wrapper/CHANGELOG.json
+++ b/packages/web3-wrapper/CHANGELOG.json
@@ -1,5 +1,15 @@
[
{
+ "timestamp": 1529397769,
+ "version": "0.7.1",
+ "changes": [
+ {
+ "note": "Dependencies updated"
+ }
+ ]
+ },
+ {
+ "timestamp": 1528070400,
"version": "0.7.0",
"changes": [
{
diff --git a/packages/web3-wrapper/CHANGELOG.md b/packages/web3-wrapper/CHANGELOG.md
index 4b8fb7bac..1ac36a316 100644
--- a/packages/web3-wrapper/CHANGELOG.md
+++ b/packages/web3-wrapper/CHANGELOG.md
@@ -5,11 +5,19 @@ Edit the package's CHANGELOG.json file only.
CHANGELOG
+## v0.7.1 - _June 19, 2018_
+
+ * Dependencies updated
+
+## v0.7.0 - _June 4, 2018_
+
+ * Add default parameters when sending a raw payload
+
## v0.6.4 - _May 22, 2018_
* Dependencies updated
-## v0.6.3 - _May 4, 2018_
+## v0.6.3 - _May 5, 2018_
* Dependencies updated
diff --git a/packages/web3-wrapper/package.json b/packages/web3-wrapper/package.json
index de2b72ac6..3c5b2c616 100644
--- a/packages/web3-wrapper/package.json
+++ b/packages/web3-wrapper/package.json
@@ -1,6 +1,6 @@
{
"name": "@0xproject/web3-wrapper",
- "version": "0.6.4",
+ "version": "0.7.1",
"engines": {
"node": ">=6.12"
},
@@ -45,8 +45,8 @@
},
"homepage": "https://github.com/0xProject/0x-monorepo/packages/web3-wrapper/README.md",
"devDependencies": {
- "@0xproject/monorepo-scripts": "^0.1.20",
- "@0xproject/tslint-config": "^0.4.18",
+ "@0xproject/monorepo-scripts": "^0.2.1",
+ "@0xproject/tslint-config": "^0.4.20",
"@types/lodash": "4.14.104",
"chai": "^4.0.1",
"chai-as-promised": "^7.1.0",
@@ -64,10 +64,10 @@
"typescript": "2.7.1"
},
"dependencies": {
- "@0xproject/typescript-typings": "^0.3.2",
- "@0xproject/utils": "^0.6.2",
+ "@0xproject/typescript-typings": "^0.4.1",
+ "@0xproject/utils": "^0.7.1",
"ethereum-types": "^0.0.1",
- "ethers": "^3.0.15",
+ "ethers": "3.0.22",
"lodash": "^4.17.4",
"web3": "^0.20.0"
},
diff --git a/packages/web3-wrapper/src/web3_wrapper.ts b/packages/web3-wrapper/src/web3_wrapper.ts
index 5d2eedcb3..6ea69883c 100644
--- a/packages/web3-wrapper/src/web3_wrapper.ts
+++ b/packages/web3-wrapper/src/web3_wrapper.ts
@@ -491,8 +491,13 @@ export class Web3Wrapper {
}
private async _sendRawPayloadAsync<A>(payload: Partial<JSONRPCRequestPayload>): Promise<A> {
const sendAsync = this._web3.currentProvider.sendAsync.bind(this._web3.currentProvider);
- payload.id = this._jsonRpcRequestId++;
- const response = await promisify<JSONRPCResponsePayload>(sendAsync)(payload);
+ const payloadWithDefaults = {
+ id: this._jsonRpcRequestId++,
+ params: [],
+ jsonrpc: '2.0',
+ ...payload,
+ };
+ const response = await promisify<JSONRPCResponsePayload>(sendAsync)(payloadWithDefaults);
const result = response.result;
return result;
}