Reduce loop from running through all elements

- Just addign a 'last' statement once an extent is found. No since
looking for more after the extent is found because there is no more.
Should make plugin run a bit faster.
This commit is contained in:
Kevin Scott Adams 2020-07-30 14:22:22 -04:00
parent 11dc7e78bd
commit 91c192f349
1 changed files with 1 additions and 0 deletions

View File

@ -695,6 +695,7 @@ sub freenas_list_lu {
}
$node->{$freenas_api_variables->{'lunid'}} .= $iscsi_lunid;
push(@luns , $node);
last;
}
}
}