@0xproject/utils
Advanced tools
Comparing version 1.0.11 to 2.0.0
[ | ||
{ | ||
"version": "2.0.0", | ||
"changes": [ | ||
{ | ||
"note": "Make abi_decoder compatible with ethers ^4.0.0", | ||
"pr": 1069 | ||
} | ||
], | ||
"timestamp": 1538157789 | ||
}, | ||
{ | ||
"timestamp": 1537907159, | ||
@@ -4,0 +14,0 @@ "version": "1.0.11", |
@@ -8,2 +8,6 @@ <!-- | ||
## v2.0.0 - _September 28, 2018_ | ||
* Make abi_decoder compatible with ethers ^4.0.0 (#1069) | ||
## v1.0.11 - _September 25, 2018_ | ||
@@ -10,0 +14,0 @@ |
@@ -50,6 +50,6 @@ "use strict"; | ||
try { | ||
decodedData = ethersInterface.events[event.name].parse(log.data); | ||
decodedData = ethersInterface.events[event.name].decode(log.data); | ||
} | ||
catch (error) { | ||
if (error.code === "INVALID_ARGUMENT" /* INVALID_ARGUMENT */) { | ||
if (error.code === ethers.errors.INVALID_ARGUMENT) { | ||
// Because we index events by Method ID, and Method IDs are derived from the method | ||
@@ -104,3 +104,3 @@ // name and the input parameters, it's possible that the return value of the event | ||
if (abi.type === ethereum_types_1.AbiType.Event) { | ||
var topic = ethersInterface.events[abi.name].topics[0]; | ||
var topic = ethersInterface.events[abi.name].topic; | ||
var numIndexedArgs = _.reduce(abi.inputs, function (sum, input) { return (input.indexed ? sum + 1 : sum); }, 0); | ||
@@ -107,0 +107,0 @@ _this._methodIds[topic] = __assign({}, _this._methodIds[topic], (_a = {}, _a[numIndexedArgs] = abi, _a)); |
import { AbiDefinition, DataItem, MethodAbi } from 'ethereum-types'; | ||
import * as ethers from 'ethers'; | ||
declare type ParamName = null | string | NestedParamName; | ||
interface NestedParamName { | ||
name: string | null; | ||
names: ParamName[]; | ||
} | ||
declare function parseEthersParams(params: DataItem[]): { | ||
names: ethers.ParamName[]; | ||
names: ParamName[]; | ||
types: string[]; | ||
}; | ||
declare function isAbiDataEqual(name: ethers.ParamName, type: string, x: any, y: any): boolean; | ||
declare function isAbiDataEqual(name: ParamName, type: string, x: any, y: any): boolean; | ||
declare function splitTupleTypes(type: string): string[]; | ||
@@ -9,0 +13,0 @@ export declare const abiUtils: { |
{ | ||
"name": "@0xproject/utils", | ||
"version": "1.0.11", | ||
"version": "2.0.0", | ||
"engines": { | ||
@@ -44,4 +44,4 @@ "node": ">=6.12" | ||
"dependencies": { | ||
"@0xproject/types": "^1.1.1", | ||
"@0xproject/typescript-typings": "^2.0.2", | ||
"@0xproject/types": "^1.1.2", | ||
"@0xproject/typescript-typings": "^3.0.0", | ||
"@types/node": "*", | ||
@@ -51,5 +51,5 @@ "abortcontroller-polyfill": "^1.1.9", | ||
"detect-node": "2.0.3", | ||
"ethereum-types": "^1.0.8", | ||
"ethereum-types": "^1.0.9", | ||
"ethereumjs-util": "^5.1.1", | ||
"ethers": "3.0.22", | ||
"ethers": "4.0.0-beta.14", | ||
"isomorphic-fetch": "^2.2.1", | ||
@@ -62,3 +62,3 @@ "js-sha3": "^0.7.0", | ||
}, | ||
"gitHead": "1b35a6e3b5d050fa33097b35e1d739ca13c6806e" | ||
"gitHead": "ac14dd2b29b42ef4d2a46db9b70d4d30cf9bd40f" | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
76807
1232
+ Added@0xproject/typescript-typings@3.0.2(transitive)
+ Added@types/node@10.17.60(transitive)
+ Addedethers@4.0.0-beta.14(transitive)
+ Addedhash.js@1.1.3(transitive)
- Removed@0xproject/typescript-typings@2.0.2(transitive)
- Removedethers@3.0.22(transitive)
- Removedinherits@2.0.1(transitive)
Updated@0xproject/types@^1.1.2
Updatedethereum-types@^1.0.9
Updatedethers@4.0.0-beta.14