Code Duplication    Length = 8-8 lines in 2 locations

extensions/blocks/revue/revue.php 1 location

@@ 218-225 (lines=8) @@
215
	} elseif ( $has_custom_gradient ) {
216
		$styles[] = sprintf( 'background: %s;', $attributes['customGradient'] );
217
	}
218
	if (
219
		$has_custom_background_color &&
220
		! $has_named_background_color &&
221
		! $has_named_gradient &&
222
		! $has_custom_gradient
223
	) {
224
		$styles[] = sprintf( 'background-color: %s;', $attributes['customBackgroundColor'] );
225
	}
226
227
	if ( $has_border_radius ) {
228
		// phpcs:ignore WordPress.PHP.StrictComparisons.LooseComparison

extensions/blocks/button/button.php 1 location

@@ 159-166 (lines=8) @@
156
		$styles[] = sprintf( 'background: %s;', $attributes['customGradient'] );
157
	}
158
159
	if (
160
		$has_custom_background_color &&
161
		! $has_named_background_color &&
162
		! $has_named_gradient &&
163
		! $has_custom_gradient
164
	) {
165
		$styles[] = sprintf( 'background-color: %s;', $attributes['customBackgroundColor'] );
166
	}
167
168
	// phpcs:ignore WordPress.PHP.StrictComparisons.LooseComparison
169
	if ( $has_border_radius && 0 != $attributes['borderRadius'] ) {