Code Duplication    Length = 7-9 lines in 2 locations

includes/class-wc-gateway-stripe.php 1 location

@@ 322-330 (lines=9) @@
319
			data-three-d-secure="' . esc_attr( $this->three_d_secure ? 'true' : 'false' ) . '"
320
			data-allow-remember-me="' . esc_attr( apply_filters( 'wc_stripe_allow_remember_me', true ) ? 'true' : 'false' ) . '">';
321
322
		if ( $description ) {
323
			if ( $this->testmode ) {
324
				/* translators: link to Stripe testing page */
325
				$description .= ' ' . sprintf( __( 'TEST MODE ENABLED. In test mode, you can use the card number 4242424242424242 with any CVC and a valid expiration date or check the <a href="%s" target="_blank">Testing Stripe documentation</a> for more card numbers.', 'woocommerce-gateway-stripe' ), 'https://stripe.com/docs/testing' );
326
				$description  = trim( $description );
327
			}
328
329
			echo apply_filters( 'wc_stripe_description', wpautop( wp_kses_post( $description ) ), $this->id );
330
		}
331
332
		if ( $display_tokenization ) {
333
			$this->tokenization_script();

includes/payment-methods/class-wc-gateway-stripe-sepa.php 1 location

@@ 269-275 (lines=7) @@
266
			data-amount="' . esc_attr( WC_Stripe_Helper::get_stripe_amount( $total ) ) . '"
267
			data-currency="' . esc_attr( strtolower( get_woocommerce_currency() ) ) . '">';
268
269
		if ( $description ) {
270
			if ( $this->testmode ) {
271
				$description .= ' ' . __( 'TEST MODE ENABLED. In test mode, you can use IBAN number DE89370400440532013000.', 'woocommerce-gateway-stripe' );
272
				$description  = trim( $description );
273
			}
274
			echo apply_filters( 'wc_stripe_description', wpautop( wp_kses_post( $description ) ), $this->id );
275
		}
276
277
		if ( $display_tokenization ) {
278
			$this->tokenization_script();