mirror of
https://github.com/PretendoNetwork/website.git
synced 2026-08-23 09:07:40 -05:00
fix: fixed miidata not loading properly
This commit is contained in:
@@ -65,9 +65,7 @@ const newMiiSmileUrl = computed(() => {
|
||||
});
|
||||
|
||||
function base64ToArrayBuffer(base64: string): ArrayBuffer {
|
||||
const binaryString = atob(base64);
|
||||
const binaryArray = new TextEncoder().encode(binaryString);
|
||||
return binaryArray.buffer;
|
||||
return new Uint8Array([...atob(base64)].map(v => v.charCodeAt(0))).buffer;
|
||||
}
|
||||
|
||||
// this initalizes a mii for editing
|
||||
@@ -89,7 +87,8 @@ function initializeMiiData(encodedUserMiiData: string) {
|
||||
bgColor: '13173300',
|
||||
expression: 'sorrow'
|
||||
});
|
||||
} catch {
|
||||
} catch (err) {
|
||||
console.error('Failed to load mii data', err);
|
||||
return false;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user