Skip to content

Commit

Permalink
Restructuring code for better code coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
ivanwills committed Apr 16, 2016
1 parent e5d4c29 commit 9f0ec76
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion lib/VCS/Which.pm
Original file line number Diff line number Diff line change
Expand Up @@ -137,7 +137,9 @@ sub which {
my $used = eval { $system->used($dir) || 0 };
next if $EVAL_ERROR;

$min ||= $used if $used;
if ( $used && ! defined $min ) {
$min = $used;
}

# check that the directory is used and that it was found at a level closer to $dir that the last found system
if ( $used && $used <= $min ) {
Expand Down

0 comments on commit 9f0ec76

Please sign in to comment.