Code Duplication    Length = 6-6 lines in 2 locations

includes/librairies/purchase/checkout.class.php 1 location

@@ 216-221 (lines=6) @@
213
					}
214
				}
215
216
				if ( empty($_SESSION['wps-pos-addon']) ) {
217
					$email_option = get_option('wpshop_emails');
218
					if( empty($email_option) || ( !empty($email_option) && empty($email_option['send_confirmation_order_message']) ) ){
219
						self::send_order_email_to_administrator( $order_id, $user_info );
220
					}
221
				}
222
223
224
				/** IF Order amount is 0, Finish the Order **/

includes/librairies/payments/payment.class.php 1 location

@@ 591-596 (lines=6) @@
588
					update_post_meta($order_id, '_' . WPSHOP_NEWTYPE_IDENTIFIER_ORDER . '_completed_date', current_time('mysql', 0));
589
590
					// Send confirmation e-mail to administrator
591
					if ( empty($_SESSION['wps-pos-addon']) ) {
592
						$email_option = get_option('wpshop_emails');
593
						if(  !empty($email_option) && !empty($email_option['send_confirmation_order_message']) ){
594
							wpshop_checkout::send_order_email_to_administrator( $order_id, $user_data );
595
						}
596
					}
597
598
					// POS Status
599
					if( !empty($order_meta['order_payment']) && !empty($order_meta['order_payment']['shipping_method']) && $order_meta['order_payment']['shipping_method'] == 'default_shipping_mode_for_pos' ) {