Code Duplication    Length = 6-6 lines in 2 locations

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

@@ 520-525 (lines=6) @@
517
518
		$donors = wp_cache_get( $cache_key, 'donors' );
519
520
		if ( $donors === false ) {
521
			$donors = new Give_Donors_Query( $args );
522
			$donors = $donors->get_donors();
523
524
			wp_cache_set( $cache_key, $donors, 'donors', 3600 );
525
		}
526
527
		return $donors;
528
@@ 549-554 (lines=6) @@
546
		$cache_key = md5( 'give_donors_count' . serialize( $args ) );
547
		$count     = wp_cache_get( $cache_key, 'donors' );
548
549
		if ( $count === false ) {
550
			$donors = new Give_Donors_Query( $args );
551
			$count  = $donors->get_donors();
552
553
			wp_cache_set( $cache_key, $count, 'donors', 3600 );
554
		}
555
556
		return absint( $count );
557