From c2801c447db57599daffd0bfff07d88921993c1e Mon Sep 17 00:00:00 2001 From: AsamK Date: Wed, 22 Dec 2021 19:19:19 +0100 Subject: [PATCH] Return unknown version if project version is not available --- src/main/java/org/asamk/signal/commands/VersionCommand.java | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/main/java/org/asamk/signal/commands/VersionCommand.java b/src/main/java/org/asamk/signal/commands/VersionCommand.java index 51f805a9..95b41598 100644 --- a/src/main/java/org/asamk/signal/commands/VersionCommand.java +++ b/src/main/java/org/asamk/signal/commands/VersionCommand.java @@ -30,6 +30,7 @@ public class VersionCommand implements JsonRpcSingleCommand, JsonRpcMultiC } private void outputVersion(final JsonWriter jsonWriter) { - jsonWriter.write(Map.of("version", BaseConfig.PROJECT_VERSION)); + jsonWriter.write(Map.of("version", + BaseConfig.PROJECT_VERSION == null ? "unknown" : BaseConfig.PROJECT_VERSION)); } }