From 03a7016e86e47cf8b096b21c58a6a05e8488a13c Mon Sep 17 00:00:00 2001 From: Oliver Liu Date: Fri, 3 May 2019 15:42:11 +1000 Subject: [PATCH] set custom_types to array fixes #28 Set $custom_types to an empty array by default. An array is expected by other filter functions. --- rapid-addon.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/rapid-addon.php b/rapid-addon.php index f6a0e1a..8fd178d 100644 --- a/rapid-addon.php +++ b/rapid-addon.php @@ -1167,7 +1167,7 @@ public function remove_post_type( $type = '' ) { } } - public function filter_post_types( $custom_types = '', $custom_type = '' ) { + public function filter_post_types( $custom_types = array(), $custom_type = '' ) { $options = $this->options_array(); $option_key = 'post_types_to_remove'; @@ -1276,4 +1276,4 @@ public function post_type_image( $image ) { return $image; } } -} \ No newline at end of file +}