Code Duplication    Length = 16-16 lines in 2 locations

includes/shipping/legacy-local-pickup/class-wc-shipping-legacy-local-pickup.php 1 location

@@ 41-56 (lines=16) @@
38
	/**
39
	 * init function.
40
	 */
41
	public function init() {
42
43
		// Load the settings.
44
		$this->init_form_fields();
45
		$this->init_settings();
46
47
		// Define user set variables
48
		$this->enabled		= $this->get_option( 'enabled' );
49
		$this->title		= $this->get_option( 'title' );
50
		$this->codes		= $this->get_option( 'codes' );
51
		$this->availability	= $this->get_option( 'availability' );
52
		$this->countries	= $this->get_option( 'countries' );
53
54
		// Actions
55
		add_action( 'woocommerce_update_options_shipping_' . $this->id, array( $this, 'process_admin_options' ) );
56
	}
57
58
	/**
59
	 * calculate_shipping function.

includes/shipping/local-pickup/class-wc-shipping-local-pickup.php 1 location

@@ 36-51 (lines=16) @@
33
	/**
34
	 * Initialize local pickup.
35
	 */
36
	public function init() {
37
38
		// Load the settings.
39
		$this->init_form_fields();
40
		$this->init_settings();
41
42
		// Define user set variables
43
		$this->enabled		= $this->get_option( 'enabled' );
44
		$this->title		= $this->get_option( 'title' );
45
		$this->codes		= $this->get_option( 'codes' );
46
		$this->availability	= $this->get_option( 'availability' );
47
		$this->countries	= $this->get_option( 'countries' );
48
49
		// Actions
50
		add_action( 'woocommerce_update_options_shipping_' . $this->id, array( $this, 'process_admin_options' ) );
51
	}
52
53
	/**
54
	 * calculate_shipping function.