Allow custom cache expiry

This commit is contained in:
2024-02-11 14:40:11 +11:00
parent 081de8b98e
commit d83dac92a5
3 changed files with 8 additions and 6 deletions

View File

@@ -7,7 +7,7 @@ module Adamantium
include Deps["views.recently_played.index"]
def handle(req, res)
res.body = cache(key: "recently_played", content: index.call.to_str)
res.body = cache(key: "recently_played", content_proc: -> { index.call.to_str })
end
end
end