Skip to content

Commit 95db1e9

Browse files
committed
Fix
1 parent 6c7a149 commit 95db1e9

File tree

1 file changed

+9
-1
lines changed

1 file changed

+9
-1
lines changed

src/wp-includes/rest-api/endpoints/class-wp-rest-global-styles-revisions-controller.php

Lines changed: 9 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,6 +31,14 @@ class WP_REST_Global_Styles_Revisions_Controller extends WP_REST_Revisions_Contr
3131
*/
3232
protected $parent_base;
3333

34+
/**
35+
* Parent post type.
36+
*
37+
* @since 6.5.0
38+
* @var string
39+
*/
40+
protected $parent_post_type;
41+
3442
/**
3543
* Constructor.
3644
*
@@ -39,7 +47,7 @@ class WP_REST_Global_Styles_Revisions_Controller extends WP_REST_Revisions_Contr
3947
*
4048
* @param string $parent_post_type Post type of the parent.
4149
*/
42-
public function __construct( $parent_post_type ) {
50+
public function __construct( $parent_post_type = 'wp_global_styles' ) {
4351
parent::__construct( $parent_post_type );
4452
$post_type_object = get_post_type_object( $parent_post_type );
4553
$parent_controller = $post_type_object->get_rest_controller();

0 commit comments

Comments
 (0)