Skip to content

Commit

Permalink
rename filter
Browse files Browse the repository at this point in the history
  • Loading branch information
aristath committed Dec 4, 2020
1 parent a54fec5 commit 25c9da5
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions lib/class-wp-theme-json-resolver.php
Original file line number Diff line number Diff line change
Expand Up @@ -308,25 +308,25 @@ public function get_origin( $theme_support_data = array(), $origin = 'user', $me
$result->merge( $this->get_theme_origin( $theme_support_data ) );
$result->merge( self::get_user_origin() );
/* This filter is documented in lib/class-wp-theme-json-resolver.php */
return apply_filters( 'get_global_styles_data', $result, $origin, $theme_support_data );
return apply_filters( 'global_styles_get_data', $result, $origin, $theme_support_data );
}

if ( ( 'theme' === $origin ) && $merged ) {
$result = new WP_Theme_JSON();
$result->merge( self::get_core_origin() );
$result->merge( $this->get_theme_origin( $theme_support_data ) );
/* This filter is documented in lib/class-wp-theme-json-resolver.php */
return apply_filters( 'get_global_styles_data', $result, $origin, $theme_support_data );
return apply_filters( 'global_styles_get_data', $result, $origin, $theme_support_data );
}

if ( 'user' === $origin ) {
/* This filter is documented in lib/class-wp-theme-json-resolver.php */
return apply_filters( 'get_global_styles_data', self::get_user_origin(), $origin, $theme_support_data );
return apply_filters( 'global_styles_get_data', self::get_user_origin(), $origin, $theme_support_data );
}

if ( 'theme' === $origin ) {
/* This filter is documented in lib/class-wp-theme-json-resolver.php */
return apply_filters( 'get_global_styles_data', $this->get_theme_origin( $theme_support_data ), $origin, $theme_support_data );
return apply_filters( 'global_styles_get_data', $this->get_theme_origin( $theme_support_data ), $origin, $theme_support_data );
}

/**
Expand All @@ -339,7 +339,7 @@ public function get_origin( $theme_support_data = array(), $origin = 'user', $me
*
* @return WP_Theme_JSON
*/
return apply_filters( 'get_global_styles_data', self::get_core_origin(), $origin, $theme_support_data );
return apply_filters( 'global_styles_get_data', self::get_core_origin(), $origin, $theme_support_data );
}

/**
Expand Down

0 comments on commit 25c9da5

Please sign in to comment.