From 86609d76c90ab4981c5754f8cb410313ebc3dc0d Mon Sep 17 00:00:00 2001 From: Dustin Utecht Date: Fri, 13 Mar 2020 11:16:13 +0100 Subject: [PATCH] check if the contentType is null --- src/EventListener/StorageListener.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/EventListener/StorageListener.php b/src/EventListener/StorageListener.php index 8f690d9..17793cc 100644 --- a/src/EventListener/StorageListener.php +++ b/src/EventListener/StorageListener.php @@ -188,6 +188,11 @@ public function preSave(StorageEvent $event) } $contentType = $this->boltConfig->get('contenttypes/' . $event->getContentType()); + + if ($contentType === null) { + return; + } + $translatableFields = $this->getTranslatableFields($contentType['fields']); /** @var Content $record */ $record = $event->getContent();