Code Duplication    Length = 7-9 lines in 2 locations

php/elFinderVolumeDriver.class.php 2 locations

@@ 754-762 (lines=9) @@
751
			'hidden'  => false
752
		);
753
		// set files attributes
754
		if (!empty($this->options['attributes']) && is_array($this->options['attributes'])) {
755
			
756
			foreach ($this->options['attributes'] as $a) {
757
				// attributes must contain pattern and at least one rule
758
				if (!empty($a['pattern']) || count($a) > 1) {
759
					$this->attributes[] = $a;
760
				}
761
			}
762
		}
763
764
		if (!empty($this->options['accessControl']) && is_callable($this->options['accessControl'])) {
765
			$this->access = $this->options['accessControl'];
@@ 939-945 (lines=7) @@
936
937
		$this->_checkArchivers();
938
		// manual control archive types to create
939
		if (!empty($this->options['archiveMimes']) && is_array($this->options['archiveMimes'])) {
940
			foreach ($this->archivers['create'] as $mime => $v) {
941
				if (!in_array($mime, $this->options['archiveMimes'])) {
942
					unset($this->archivers['create'][$mime]);
943
				}
944
			}
945
		}
946
		
947
		// manualy add archivers
948
		if (!empty($this->options['archivers']['create']) && is_array($this->options['archivers']['create'])) {