From fd4eeb76218f0ab334eb2a281642f9c3284df786 Mon Sep 17 00:00:00 2001 From: leuc Date: Fri, 15 Feb 2019 21:15:02 +0100 Subject: [PATCH] Use an hour as default cache time for status transform, to avoid stale cache objects --- app/Transformer/Api/StatusTransformer.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/app/Transformer/Api/StatusTransformer.php b/app/Transformer/Api/StatusTransformer.php index 58ac69a9..3710aa1f 100644 --- a/app/Transformer/Api/StatusTransformer.php +++ b/app/Transformer/Api/StatusTransformer.php @@ -17,7 +17,7 @@ class StatusTransformer extends Fractal\TransformerAbstract public function transform(Status $status) { - return Cache::remember('transform:status:'. $status->url(), 3, function() use($status) { + return Cache::remember('transform:status:'. $status->url(), 60, function() use($status) { return [ 'id' => (string) $status->id, 'uri' => $status->url(),