From 2a390c589334a7e1220d6dc3931b5d46fbfffbf3 Mon Sep 17 00:00:00 2001 From: Alexander Suetin Date: Tue, 29 Aug 2023 02:02:41 +0800 Subject: [PATCH] Fix: Undefined property: WP_Post_Type::ID in single custom post type --- src/Crumb.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/Crumb.php b/src/Crumb.php index 1685a1e..1474f5e 100644 --- a/src/Crumb.php +++ b/src/Crumb.php @@ -228,7 +228,7 @@ public function build() $this->add( $type->label, get_post_type_archive_link($type->name), - $type->ID + get_queried_object_id() ); }