mirror of
https://github.com/Terncode/pixel.horse.git
synced 2026-09-24 21:55:52 +02:00
Downgrade TypeScript, remove hacks
This commit is contained in:
@@ -18,9 +18,9 @@ export function getWebGLContext(canvas: HTMLCanvasElement): WebGLRenderingContex
|
||||
antialias: false,
|
||||
};
|
||||
|
||||
const gl = (canvas.getContext('webgl2', options)
|
||||
const gl = canvas.getContext('webgl2', options)
|
||||
|| canvas.getContext('webgl', options)
|
||||
|| canvas.getContext('experimental-webgl', options)) as WebGLRenderingContext;
|
||||
|| canvas.getContext('experimental-webgl', options);
|
||||
|
||||
if (!gl) {
|
||||
throw new Error(WEBGL_CREATION_ERROR);
|
||||
|
||||
@@ -69,8 +69,8 @@ export async function updateAuthInfo(
|
||||
}
|
||||
|
||||
if (Object.keys(changes).length > 0) {
|
||||
Object.assign(auth, changes as IAuth);
|
||||
await updateAuth(auth._id, changes as IAuth);
|
||||
Object.assign(auth, changes);
|
||||
await updateAuth(auth._id, changes);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -102,5 +102,5 @@ async function verifyOrRestoreAuth(auth: IAuth, mergeAccount: string | undefined
|
||||
}
|
||||
|
||||
Object.assign(auth, changes);
|
||||
await updateAuth(auth._id, changes as IAuth);
|
||||
await updateAuth(auth._id, changes);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user