mirror of
https://github.com/blitzkit/blitzkit.git
synced 2026-10-23 19:49:50 +02:00
fix: missing tank icon handling
This commit is contained in:
1 parent
2504833a29
commit
fd6b69edc1
3 files changed
+20
-13
No files matched your search
@@ -7,5 +7,8 @@ export { getStaticPaths } from "./[id].pb";
|
||||
export async function GET({ params }: APIContext<never, { id: string }>) {
|
||||
const tank = await api.tank(params.id);
|
||||
const image = game.tankBigIcon(params.id, tank.tank!.visual_data);
|
||||
|
||||
if (image.length === 0) return new Response(null, { status: 404 });
|
||||
|
||||
return new Response(new Uint8Array(image));
|
||||
}
|
||||
Reference in new issue
Block a user