From c3b3520acb6c1c5982da101bd4b6ee0768795f4a Mon Sep 17 00:00:00 2001 From: Jan Henckens Date: Wed, 15 Nov 2023 20:07:42 +0100 Subject: [PATCH] Changelog for 3.3.2 --- CHANGELOG.md | 5 +++++ composer.json | 2 +- src/Scout.php | 2 +- src/jobs/DeindexElement.php | 4 ++-- 4 files changed, 9 insertions(+), 4 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 1f07b44..62bfe99 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2,6 +2,11 @@ All notable changes to this project will be documented in this file. +## 3.3.2 - 2023-11-15 +### Fixed +- Fixed an error on the Control Panel Utility page ([#284](https://github.com/studioespresso/craft-scout/issues/284)) +- Fixed an error when saving elements without a site property ([#285](https://github.com/studioespresso/craft-scout/issues/285****)) + ## 3.3.1 - 2023-11-08 ### Added diff --git a/composer.json b/composer.json index 5aeb77a..1b82bbb 100644 --- a/composer.json +++ b/composer.json @@ -2,7 +2,7 @@ "name": "studioespresso/craft-scout", "description": "Craft Scout provides a simple solution for adding full-text search to your entries. Scout will automatically keep your search indexes in sync with your entries.", "type": "craft-plugin", - "version": "3.3.1", + "version": "3.3.2", "keywords": [ "craft", "cms", diff --git a/src/Scout.php b/src/Scout.php index 565b96e..9130fdf 100644 --- a/src/Scout.php +++ b/src/Scout.php @@ -203,7 +203,7 @@ function (ElementEvent $event) { ->push( new DeindexElement([ 'id' => $element->id, - 'siteId' => $element->site->id + 'siteId' => $element->site ? $element->site->id : null ]) ); } diff --git a/src/jobs/DeindexElement.php b/src/jobs/DeindexElement.php index cff5e6b..50149e9 100644 --- a/src/jobs/DeindexElement.php +++ b/src/jobs/DeindexElement.php @@ -11,8 +11,8 @@ class DeindexElement extends BaseJob /** @var int */ public $id; - /** @var int */ - public int $siteId; + /** @var int|null */ + public int|null $siteId; public function execute($queue): void {