Skip to content

Commit

Permalink
Fixed typo in error message (#470).
Browse files Browse the repository at this point in the history
  • Loading branch information
ricmoo committed May 24, 2019
1 parent 80423ac commit 47d92ae
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/strings/src.ts/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,7 @@ export function parseBytes32String(bytes: BytesLike): string {

// Must be 32 bytes with a null-termination
if (data.length !== 32) { throw new Error("invalid bytes32 - not 32 bytes long"); }
if (data[31] !== 0) { throw new Error("invalid bytes32 sdtring - no null terminator"); }
if (data[31] !== 0) { throw new Error("invalid bytes32 string - no null terminator"); }

// Find the null termination
let length = 31;
Expand Down

0 comments on commit 47d92ae

Please sign in to comment.