Code Duplication    Length = 9-9 lines in 2 locations

includes/class-wc-stripe-apple-pay.php 2 locations

@@ 228-236 (lines=9) @@
225
			return;
226
		}
227
228
		if ( is_single() ) {
229
			global $post;
230
231
			$product = wc_get_product( $post->ID );
232
233
			if ( ! in_array( ( version_compare( WC_VERSION, '3.0.0', '<' ) ? $product->product_type : $product->get_type() ), $this->supported_product_types() ) ) {
234
				return;
235
			}
236
		}
237
238
		$apple_pay_button = ! empty( $this->_gateway_settings['apple_pay_button'] ) ? $this->_gateway_settings['apple_pay_button'] : 'black';
239
		$button_lang      = ! empty( $this->_gateway_settings['apple_pay_button_lang'] ) ? strtolower( $this->_gateway_settings['apple_pay_button_lang'] ) : 'en';
@@ 267-275 (lines=9) @@
264
			return;
265
		}
266
267
		if ( is_single() ) {
268
			global $post;
269
270
			$product = wc_get_product( $post->ID );
271
272
			if ( ! in_array( ( version_compare( WC_VERSION, '3.0.0', '<' ) ? $product->product_type : $product->get_type() ), $this->supported_product_types() ) ) {
273
				return;
274
			}
275
		}
276
		?>
277
		<p class="apple-pay-button-checkout-separator">- <?php esc_html_e( 'Or', 'woocommerce-gateway-stripe' ); ?> -</p>
278
		<?php