diff options
| author | Abdelaziz Mahdy <[email protected]> | 2024-12-23 03:27:43 -0400 |
|---|---|---|
| committer | Abdelaziz Mahdy <[email protected]> | 2024-12-23 03:27:43 -0400 |
| commit | dfc278be08b64dc9bb3082059648c5f792a79fcb (patch) | |
| tree | 7d79ddcf7abf4ad1eea638b9d9544316ca64e6a3 /src/config | |
| parent | f1f5db84f98818af2c047ea375832e5ded5f021a (diff) | |
| download | aniwatch-api-dfc278be08b64dc9bb3082059648c5f792a79fcb.tar.xz aniwatch-api-dfc278be08b64dc9bb3082059648c5f792a79fcb.zip | |
chore: styling changes to be more consistent
Diffstat (limited to 'src/config')
| -rw-r--r-- | src/config/cacheControlMiddleware.ts (renamed from src/config/cache_control_middleware.ts) | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/config/cache_control_middleware.ts b/src/config/cacheControlMiddleware.ts index 5543ddc..47035ed 100644 --- a/src/config/cache_control_middleware.ts +++ b/src/config/cacheControlMiddleware.ts @@ -2,8 +2,8 @@ import type { MiddlewareHandler } from "hono"; // Define middleware to add Cache-Control header const cacheControlMiddleware: MiddlewareHandler = async (c, next) => { - const sMaxAge = process.env.S_MAXAGE || "60"; - const staleWhileRevalidate = process.env.STALE_WHILE_REVALIDATE || "30"; + const sMaxAge = process.env.ANIWATCH_API_S_MAXAGE || "60"; + const staleWhileRevalidate = process.env.ANIWATCH_API_STALE_WHILE_REVALIDATE || "30"; c.header( "Cache-Control", `s-maxage=${sMaxAge}, stale-while-revalidate=${staleWhileRevalidate}` |
