Skip to content

Commit

Permalink
Lint
Browse files Browse the repository at this point in the history
  • Loading branch information
evert committed Oct 2, 2024
1 parent ca00732 commit 1d9aaff
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions src/util.ts
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,8 @@ export function arrayBufferToBase64(ab: ArrayBuffer): string {
let binary = '';

// Convert each byte to a character
for (let i = 0; i < bytes.length; i++) {
binary += String.fromCharCode(bytes[i]);
for (const byte of bytes) {
binary += String.fromCharCode(byte);
}

// Encode the binary string as Base64
Expand All @@ -55,7 +55,7 @@ export function base64ToArrayBuffer(b64: string): ArrayBuffer {

// Convert each character to its corresponding byte
for (let i = 0; i < len; i++) {
bytes[i] = binaryString.charCodeAt(i);
bytes[i] = binaryString.charCodeAt(i);
}

// Return the ArrayBuffer
Expand Down

0 comments on commit 1d9aaff

Please sign in to comment.