Skip to content

Commit dd90275

Browse files
committed
changes from testing
1 parent 4f0ba84 commit dd90275

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

cache/middleware.js

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -470,8 +470,9 @@ const invalidateCache = (req, res, next) => {
470470
*/
471471
const cacheStats = (req, res) => {
472472
const stats = cache.getStats()
473-
const details = req.query.details === 'true' ? cache.getStats() : undefined
474-
res.status(200).json(stats)
473+
const response = { stats }
474+
if (req.query.details === 'true') response.details = cache.getDetailsByEntry()
475+
res.status(200).json(response)
475476
}
476477

477478
/**

0 commit comments

Comments
 (0)