Skip to content
This repository was archived by the owner on Sep 26, 2023. It is now read-only.

Commit e4605fd

Browse files
committed
Update GCloudEmulatorRunner.java
currentVersion may be null when using an older GCLOUD SDK without the searched emulator.
1 parent 1c0411b commit e4605fd

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/main/java/com/google/api/gax/testing/GCloudEmulatorRunner.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -81,7 +81,7 @@ private boolean isGCloudInstalled() {
8181
private boolean isEmulatorUpdateToDate()
8282
throws IOException, InterruptedException {
8383
String currentVersion = installedEmulatorVersion(versionPrefix);
84-
return currentVersion.compareTo(minVersion) >= 0;
84+
return currentVersion != null && currentVersion.compareTo(minVersion) >= 0;
8585
}
8686

8787
private String installedEmulatorVersion(String versionPrefix)

0 commit comments

Comments
 (0)