diff --git a/src/Controller/ProductPhotosController.php b/src/Controller/ProductPhotosController.php index deac217..6a3a483 100644 --- a/src/Controller/ProductPhotosController.php +++ b/src/Controller/ProductPhotosController.php @@ -126,7 +126,7 @@ class ProductPhotosController extends AppController throw new ForbiddenException('Failed to create the required folders. Please check the folder permissions and try again.'); } } - $destination = $fullPath . DS . $uuid; + $destination = $fullPath . DS . $uuid . '.' . $ext; // Existing files with the same name will be replaced. $photoObject->moveTo($destination);