From 92439a4cdb34565eeacc8220c83e6b94423b404f Mon Sep 17 00:00:00 2001 From: Kekskurse Date: Sun, 17 Jan 2021 03:13:59 +0100 Subject: [PATCH] Test --- app/Http/Controllers/PublicController.php | 3 +-- app/Jobs/ResizeImage.php | 2 +- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/app/Http/Controllers/PublicController.php b/app/Http/Controllers/PublicController.php index 4378c68..8538192 100644 --- a/app/Http/Controllers/PublicController.php +++ b/app/Http/Controllers/PublicController.php @@ -70,8 +70,7 @@ class PublicController extends BaseController //Return from s3, takes a loooong time - $resizeJob = new ResizeImage((integer)$image->id, $size); - ResizeImage::dispatchSync($resizeJob); + ResizeImage::dispatchSync($image->id, $size); $r = $this->tryReturnFromCache($cacheName."_".$size, $tenant->id, $gallery->id, $image->id); if($r != null) { diff --git a/app/Jobs/ResizeImage.php b/app/Jobs/ResizeImage.php index 88e65f2..408a754 100644 --- a/app/Jobs/ResizeImage.php +++ b/app/Jobs/ResizeImage.php @@ -29,7 +29,7 @@ class ResizeImage implements ShouldQueue * * @return void */ - public function __construct($image_id, $size) + public function __construct(int $image_id, int $size) { $this->image_id = $image_id; $this->size = $size;