Skip to content

Commit

Permalink
Integrate the processor class
Browse files Browse the repository at this point in the history
  • Loading branch information
ramonjd committed Jul 24, 2022
1 parent f2de4c7 commit 313019d
Showing 1 changed file with 2 additions and 11 deletions.
13 changes: 2 additions & 11 deletions packages/style-engine/class-wp-style-engine.php
Original file line number Diff line number Diff line change
Expand Up @@ -373,17 +373,8 @@ public static function process_and_enqueue_stored_styles() {
continue;
}

$css_rules = $store_instance->get_all_rules();

if ( empty( $css_rules ) ) {
continue;
}

$styles_output = '';

foreach ( $css_rules as $css_rule ) {
$styles_output .= $css_rule->get_css();
}
$processor = new WP_Style_Engine_Processor( $store_instance );
$styles_output = $processor->get_css();

if ( ! empty( $styles_output ) ) {
wp_register_style( $store_key, false, array(), true, true );
Expand Down

0 comments on commit 313019d

Please sign in to comment.