mirror of
https://github.com/pixelfed/pixelfed.git
synced 2024-12-24 00:35:59 +00:00
Update StatusService, fix json bug
This commit is contained in:
parent
3a428366fb
commit
1ea2db74b2
1 changed files with 4 additions and 2 deletions
|
@ -2,9 +2,11 @@
|
|||
|
||||
namespace App\Services;
|
||||
|
||||
use Redis;
|
||||
use Illuminate\Support\Facades\Redis;
|
||||
use App\Status;
|
||||
//use App\Transformer\Api\v3\StatusTransformer;
|
||||
use App\Transformer\Api\StatusStatelessTransformer;
|
||||
use App\Transformer\Api\StatusTransformer;
|
||||
use League\Fractal;
|
||||
use League\Fractal\Serializer\ArraySerializer;
|
||||
use League\Fractal\Pagination\IlluminatePaginatorAdapter;
|
||||
|
@ -15,7 +17,7 @@ class StatusService {
|
|||
|
||||
public static function get($id)
|
||||
{
|
||||
return Redis::get(self::CACHE_KEY . $id) ?? self::coldGet($id);
|
||||
return json_decode(Redis::get(self::CACHE_KEY . $id) ?? self::coldGet($id));
|
||||
}
|
||||
|
||||
public static function coldGet($id)
|
||||
|
|
Loading…
Reference in a new issue