From 1b89cadab5b36cd86895df46d6b54e757cfd4df5 Mon Sep 17 00:00:00 2001 From: WebStreamr <210764791+webstreamr@users.noreply.github.com> Date: Tue, 2 Sep 2025 14:51:31 +0000 Subject: [PATCH] chore: always return integers for Cache-Control max-age --- src/controller/StreamController.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/controller/StreamController.ts b/src/controller/StreamController.ts index 0f464f1..e7086ff 100644 --- a/src/controller/StreamController.ts +++ b/src/controller/StreamController.ts @@ -54,7 +54,7 @@ export class StreamController { const { streams, ttl } = await this.streamResolver.resolve(ctx, sources, type, id); if (ttl && envIsProd()) { - res.setHeader('Cache-Control', `max-age=${ttl / 1000}, public`); + res.setHeader('Cache-Control', `max-age=${Math.floor(ttl / 1000)}, public`); } res.setHeader('Content-Type', 'application/json');