diff options
author | bobzel <zzzman@gmail.com> | 2023-08-10 11:31:05 -0400 |
---|---|---|
committer | bobzel <zzzman@gmail.com> | 2023-08-10 11:31:05 -0400 |
commit | 2cea22bea6b335820b1030ca75ebeca4364b6769 (patch) | |
tree | fd64b8f06123e47b3b0a4fccb14536faf1bb247a /src/server/server_Initialization.ts | |
parent | 36a03dc893437b22571bf6ce398f6cb7c3ad89b3 (diff) |
added client caching of jpg's in addition to png's. modified jitterRotation to _rotation_jitter and changed where it is used.
Diffstat (limited to 'src/server/server_Initialization.ts')
-rw-r--r-- | src/server/server_Initialization.ts | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/server/server_Initialization.ts b/src/server/server_Initialization.ts index 322d6458c..354f809e0 100644 --- a/src/server/server_Initialization.ts +++ b/src/server/server_Initialization.ts @@ -100,7 +100,7 @@ function buildWithMiddleware(server: express.Express) { passport.session(), (req: express.Request, res: express.Response, next: express.NextFunction) => { res.locals.user = req.user; - if ((req.originalUrl.endsWith('.png') || (process.env.RELEASE === 'true' && req.originalUrl.endsWith(".js"))) && req.method === 'GET' ) { + if ((req.originalUrl.endsWith('.png') || req.originalUrl.endsWith('.jpg') || (process.env.RELEASE === 'true' && req.originalUrl.endsWith('.js'))) && req.method === 'GET') { const period = 30000; res.set('Cache-control', `public, max-age=${period}`); } else { |