cpt filter update & function update

This commit is contained in:
magepeopleteam 2022-01-05 10:42:51 +00:00
parent a0f165672f
commit a940166858
2 changed files with 2 additions and 2 deletions

View File

@ -44,7 +44,7 @@ function mep_cpt()
); );
$rewrite = array( $rewrite = array(
'slug' => 'mage-events', 'slug' => $event_slug,
'with_front' => true, 'with_front' => true,
'pages' => true, 'pages' => true,
'feeds' => true, 'feeds' => true,

View File

@ -1682,7 +1682,7 @@ if (!function_exists('mep_event_list_price')) {
$price_arr[] = array_key_exists('option_price_t',$ticket) ? $ticket['option_price_t'] : null; $price_arr[] = array_key_exists('option_price_t',$ticket) ? $ticket['option_price_t'] : null;
} }
} }
$price_arr = sizeof($price_arr) > 0 ? $price_arr : [0];
return $type == 'price' ? wc_price(min($price_arr)) : count($price_arr); return $type == 'price' ? wc_price(min($price_arr)) : count($price_arr);
} }
} }