Skip to content

Commit

Permalink
fix node test import, and set stringToBuffer encoding
Browse files Browse the repository at this point in the history
  • Loading branch information
connor4312 committed Jan 6, 2024
1 parent 004f9c6 commit 939e884
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/data-uri-to-buffer/src/node.ts
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ function base64ToArrayBuffer(base64: string) {
}

function stringToBuffer(str: string): ArrayBuffer {
return nodeBuffertoArrayBuffer(Buffer.from(str));
return nodeBuffertoArrayBuffer(Buffer.from(str, 'ascii'));
}

/**
Expand Down

0 comments on commit 939e884

Please sign in to comment.