Rename method for clarity

This commit is contained in:
Fabio Berger
2018-03-20 21:41:21 +00:00
parent 4f76bb2a12
commit 647bc5a63e
2 changed files with 2 additions and 2 deletions

View File

@@ -260,7 +260,7 @@ export class ZeroEx {
msgHashHex = ethUtil.bufferToHex(msgHashBuff);
}
const signature = await this._web3Wrapper.signTransactionAsync(normalizedSignerAddress, msgHashHex);
const signature = await this._web3Wrapper.signMessageAsync(normalizedSignerAddress, msgHashHex);
// HACK: There is no consensus on whether the signatureHex string should be formatted as
// v + r + s OR r + s + v, and different clients (even different versions of the same client)

View File

@@ -70,7 +70,7 @@ export class Web3Wrapper {
const codeIsEmpty = /^0x0{0,40}$/i.test(code);
return !codeIsEmpty;
}
public async signTransactionAsync(address: string, message: string): Promise<string> {
public async signMessageAsync(address: string, message: string): Promise<string> {
const signData = await promisify<string>(this._web3.eth.sign)(address, message);
return signData;
}