Code Duplication    Length = 8-10 lines in 2 locations

lib/elFinderVolumeLocalFileSystem.class.php 2 locations

@@ 579-586 (lines=8) @@
576
577
	    if ($uid) {
578
	        $stat['isowner'] = ($phpuid == $uid);
579
	        if (isset($names['uid'][$uid])) {
580
	            $stat['owner'] = $names['uid'][$uid];
581
	        } elseif (is_callable('posix_getpwuid')) {
582
	            $pwuid = posix_getpwuid($uid);
583
	            $stat['owner'] = $names['uid'][$uid] = $pwuid['name'];
584
	        } else {
585
	            $stat['owner'] = $names['uid'][$uid] = $uid;
586
	        }
587
	    }
588
	    if ($gid) {
589
	        if (isset($names['gid'][$gid])) {
@@ 588-597 (lines=10) @@
585
	            $stat['owner'] = $names['uid'][$uid] = $uid;
586
	        }
587
	    }
588
	    if ($gid) {
589
	        if (isset($names['gid'][$gid])) {
590
	            $stat['group'] = $names['gid'][$gid];
591
	        } elseif (is_callable('posix_getgrgid')) {
592
	            $grgid = posix_getgrgid($gid);
593
	            $stat['group'] = $names['gid'][$gid] = $grgid['name'];
594
	        } else {
595
	            $stat['group'] = $names['gid'][$gid] = $gid;
596
	        }
597
	    }
598
599
	    return $stat;
600
	}