Code Duplication    Length = 3-3 lines in 2 locations

src/wordlift/cache/class-ttl-cache.php 2 locations

@@ 78-80 (lines=3) @@
75
76
		// Get the temp dir and add the directory separator if missing.
77
		$temp_dir = get_temp_dir();
78
		if ( DIRECTORY_SEPARATOR !== substr( $temp_dir, - strlen( DIRECTORY_SEPARATOR ) ) ) {
79
			$temp_dir .= DIRECTORY_SEPARATOR;
80
		}
81
		$this->cache_dir = self::get_cache_folder() . DIRECTORY_SEPARATOR . md5( $name );
82
83
		$this->log->trace( "Creating the cache folder {$this->cache_dir}..." );
@@ 102-104 (lines=3) @@
99
100
		// Get the temp dir and add the directory separator if missing.
101
		$temp_dir = get_temp_dir();
102
		if ( DIRECTORY_SEPARATOR !== substr( $temp_dir, - strlen( DIRECTORY_SEPARATOR ) ) ) {
103
			$temp_dir .= DIRECTORY_SEPARATOR;
104
		}
105
106
		return $temp_dir . 'wl.cache';
107
	}