Make WordPress Core


Ignore:
Timestamp:
12/14/2021 04:12:57 PM (3 years ago)
Author:
hellofromTonya
Message:

Themes: Rename public static functions in WP_Theme_JSON_Resolver to remove custom_post_type references.

WordPress Core is not really custom and does not reference "custom post type" in its function naming. This commit renames 2 public static methods:

  • WP_Theme_JSON_Resolver::get_user_custom_post_type_id() renamed to WP_Theme_JSON_Resolver::get_user_global_styles_post_id().
  • WP_Theme_JSON_Resolver::get_user_data_from_custom_post_type() renamed to WP_Theme_JSON_Resolver:: get_user_data_from_wp_global_styles().

Follow-up to [52049], [52051], [52069], [52232], [52275], [52364].

Props antonvlasenko, bernhard-reiter, costdev, desrosj, hellofromTonya, noisysocks, oandregal, SergeyBiryukov.
Fixes #54517.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-admin/site-editor.php

    r52364 r52372  
    6565}
    6666
    67 $active_global_styles_id = WP_Theme_JSON_Resolver::get_user_custom_post_type_id();
     67$active_global_styles_id = WP_Theme_JSON_Resolver::get_user_global_styles_post_id();
    6868$active_theme            = wp_get_theme()->get_stylesheet();
    6969$preload_paths           = array(
Note: See TracChangeset for help on using the changeset viewer.