Address PR comments

This commit is contained in:
Cayman 2020-02-19 13:15:57 -06:00
parent 357ae3a9eb
commit eca3c70833
2 changed files with 2 additions and 2 deletions

View File

@ -57,7 +57,7 @@ export class PublicKey {
} }
public toHexString(): string { public toHexString(): string {
return `0x${Buffer.from(this.toBytesCompressed()).toString("hex")}`; return `0x${this.toBytesCompressed().toString("hex")}`;
} }
public getValue(): PublicKeyType { public getValue(): PublicKeyType {

View File

@ -51,7 +51,7 @@ export class Signature {
domain = padLeft(domain, 8); domain = padLeft(domain, 8);
return this.value.verifyAggregatedHashWithDomain( return this.value.verifyAggregatedHashWithDomain(
publicKeys.map((key) => key.getValue()), publicKeys.map((key) => key.getValue()),
messages.map((message) => Buffer.concat([Buffer.from(message as Uint8Array), domain as Uint8Array])) messages.map((message) => Buffer.concat([message, domain]))
); );
} }