Code Duplication    Length = 8-8 lines in 2 locations

includes/payment-methods/class-wc-stripe-payment-request.php 2 locations

@@ 307-314 (lines=8) @@
304
305
		$payment_request_type = wc_clean( $_POST['payment_request_type'] );
306
307
		if ( 'apple_pay' === $payment_request_type ) {
308
			if ( WC_Stripe_Helper::is_pre_30() ) {
309
				update_post_meta( $order_id, '_payment_method_title', 'Apple Pay (Stripe)' );
310
			} else {
311
				$order->set_payment_method_title( 'Apple Pay (Stripe)' );
312
				$order->save();
313
			}
314
		}
315
316
		if ( 'payment_request_api' === $payment_request_type ) {
317
			if ( WC_Stripe_Helper::is_pre_30() ) {
@@ 316-323 (lines=8) @@
313
			}
314
		}
315
316
		if ( 'payment_request_api' === $payment_request_type ) {
317
			if ( WC_Stripe_Helper::is_pre_30() ) {
318
				update_post_meta( $order_id, '_payment_method_title', 'Chrome Payment Request (Stripe)' );
319
			} else {
320
				$order->set_payment_method_title( 'Chrome Payment Request (Stripe)' );
321
				$order->save();
322
			}
323
		}
324
	}
325
326
	/**