diff --git a/src/includes/settings/class-settings.php b/src/includes/settings/class-settings.php index 4e1e658c..6090f6ae 100644 --- a/src/includes/settings/class-settings.php +++ b/src/includes/settings/class-settings.php @@ -41,6 +41,11 @@ public function get_option( $option_name ) { if (!$options) { $options = []; } + if( isset( $options[ 'enabled_post_types'] ) && ! empty( $options[ 'enabled_post_types'] ) ) { + if ( ! is_array( $options[ 'enabled_post_types'] ) ) { + $options[ 'enabled_post_types'] = explode( ',', trim( esc_textarea( $options[ 'enabled_post_types'] ) ) ); + } + } $options = array_merge($this->default_options, $options); if ( isset($options[$option_name]) ) { return $options[$option_name]; diff --git a/src/includes/settings/settings-page.php b/src/includes/settings/settings-page.php index 543a1c69..f86bb409 100644 --- a/src/includes/settings/settings-page.php +++ b/src/includes/settings/settings-page.php @@ -44,6 +44,13 @@ +