Code Duplication    Length = 8-8 lines in 2 locations

includes/donors/class-give-donors-query.php 2 locations

@@ 624-631 (lines=8) @@
621
622
		$date_query = array();
623
624
		if ( ! empty ( $this->args['start_date'] ) ) {
625
			$date_query['after'] = date(
626
				'Y-m-d H:i:s',
627
				is_numeric( $this->args['start_date'] )
628
					? $this->args['start_date']
629
					: strtotime( $this->args['start_date'] )
630
			);
631
		}
632
633
		if ( ! empty ( $this->args['end_date'] ) ) {
634
			$date_query['before'] = date(
@@ 633-640 (lines=8) @@
630
			);
631
		}
632
633
		if ( ! empty ( $this->args['end_date'] ) ) {
634
			$date_query['before'] = date(
635
				'Y-m-d H:i:s',
636
				is_numeric( $this->args['end_date'] )
637
					? $this->args['end_date']
638
					: strtotime( $this->args['end_date'] )
639
			);
640
		}
641
642
		// Include Start Date and End Date while querying.
643
		$date_query['inclusive'] = true;