Skip to content

Commit

Permalink
Wrap raw ArrayBuffer in Uint8Array view
Browse files Browse the repository at this point in the history
  • Loading branch information
dansteren committed Sep 21, 2023
1 parent 02d9051 commit cb3d253
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/lib_new/ic.ts
Original file line number Diff line number Diff line change
Expand Up @@ -564,7 +564,7 @@ export const ic: Ic = globalThis._azleIc
},
caller: () => {
const callerBytes = globalThis._azleIc.caller();
return Principal.fromUint8Array(callerBytes);
return Principal.fromUint8Array(new Uint8Array(callerBytes));
},
candidDecode: (candidEncoded) => {
return globalThis._azleIc.candidDecode(candidEncoded.buffer);
Expand Down

0 comments on commit cb3d253

Please sign in to comment.