Skip to content

Commit

Permalink
Fix array library (#4567)
Browse files Browse the repository at this point in the history
  • Loading branch information
Flanker32 authored Aug 21, 2020
1 parent de12588 commit b8901c4
Showing 1 changed file with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -54,7 +54,6 @@
import org.apache.commons.lang.StringUtils;
import org.apache.commons.lang3.ArrayUtils;
import org.apache.maven.artifact.versioning.ComparableVersion;
import org.fest.util.Arrays;
import org.jetbrains.annotations.NotNull;

import java.io.File;
Expand Down Expand Up @@ -170,7 +169,7 @@ private ComparableVersion getFuncVersion() throws IOException, InterruptedExcept
final File func = new File(functionRunConfiguration.getFuncPath());
final String[] funcVersionResult = CommandUtils.executeMultipleLineOutput(
String.format("%s -v", func.getName()), func.getParentFile());
if (Arrays.isNullOrEmpty(funcVersionResult)) {
if (ArrayUtils.isEmpty(funcVersionResult)) {
return null;
}
return new ComparableVersion(funcVersionResult[0].trim());
Expand All @@ -183,7 +182,7 @@ private ComparableVersion getJavaVersion() throws IOException, InterruptedExcept
final File executeFolder = StringUtils.isEmpty(javaHome) ? null : Paths.get(javaHome, "bin").toFile();
final String[] javaVersionResult = CommandUtils.executeMultipleLineOutput(
"java -version", executeFolder, Process::getErrorStream); // java -version will write to std error
if (Arrays.isNullOrEmpty(javaVersionResult)) {
if (ArrayUtils.isEmpty(javaVersionResult)) {
return null;
}
final Matcher matcher = JAVA_VERSION_PATTERN.matcher(javaVersionResult[0].trim());
Expand Down

0 comments on commit b8901c4

Please sign in to comment.