From 27c910ed670cbfc6005cb95ce49c0d53c1548794 Mon Sep 17 00:00:00 2001 From: fumikito Date: Thu, 25 Sep 2025 01:08:20 +0900 Subject: [PATCH] =?UTF-8?q?Fatal=20Error=E3=82=92=E9=81=BF=E3=81=91?= =?UTF-8?q?=E3=82=8B?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/WPametu/UI/MetaBox.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/WPametu/UI/MetaBox.php b/src/WPametu/UI/MetaBox.php index ee87570..a037553 100644 --- a/src/WPametu/UI/MetaBox.php +++ b/src/WPametu/UI/MetaBox.php @@ -129,8 +129,8 @@ public function override( $post_type, $post ) { remove_meta_box( 'formatdiv', $post_type, 'side' ); break; default: - $class_uses = class_uses( $vars['class'] ); - if ( $class_uses && array_search( Taxonomy::class, $class_uses, true ) ) { + $class_uses = class_uses( $vars['class'] ) ?? []; + if ( is_array( $class_uses ) && in_array( Taxonomy::class, $class_uses, true ) ) { if ( taxonomy_exists( $name ) ) { if ( is_taxonomy_hierarchical( $name ) ) { $box_id = $name . 'div';