diff --git a/og_ui/src/BundleFormAlter.php b/og_ui/src/BundleFormAlter.php index 07c37938d..5b86077cc 100644 --- a/og_ui/src/BundleFormAlter.php +++ b/og_ui/src/BundleFormAlter.php @@ -148,7 +148,7 @@ protected function addGroupContent(array &$form, FormStateInterface $form_state) $form['og']['og_group_content_bundle'] = [ '#type' => 'checkbox', '#title' => t('Group content'), - '#default_value' => Og::isGroupContent($this->entityTypeId, $this->bundle), + '#default_value' => $this->bundle ? Og::isGroupContent($this->entityTypeId, $this->bundle) : FALSE, '#description' => empty($target_bundles) ? t('There are no group bundles defined.') : '', ];