Skip to content

Commit

Permalink
Merge pull request #205 from UtechtDustin/fix/missing-check
Browse files Browse the repository at this point in the history
Check if the contentType is null
  • Loading branch information
bobdenotter committed Mar 13, 2020
2 parents 6a3bdbc + 86609d7 commit 6c8d6ea
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions src/EventListener/StorageListener.php
Original file line number Diff line number Diff line change
Expand Up @@ -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();
Expand Down

0 comments on commit 6c8d6ea

Please sign in to comment.