Skip to content

Commit

Permalink
really maybe fix animated param
Browse files Browse the repository at this point in the history
  • Loading branch information
FieryFlames committed Nov 22, 2023
1 parent 8d3b3e6 commit 2ccd9d0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ export default {
if (!decoration) return new Response('Decoration not found', { status: 404, headers: new Headers(BASE_HEADERS) });

const animateParam = url.searchParams.get("animate")
const animate = decoration.animated && ((!!animateParam && animateParam === "true") ?? filename.startsWith('a_'));
const animate = decoration.animated && ((animateParam ? animateParam === "true" : null) ?? filename.startsWith('a_'));

const object = await env.UGC.get(getFileName(hash, animate));
if (!object) return new Response('Not Found', { status: 404, headers: new Headers(BASE_HEADERS) });
Expand Down

0 comments on commit 2ccd9d0

Please sign in to comment.