diff options
author | Gavriel Fleischer <flocsy@gmail.com> | 2019-11-11 00:26:01 +0200 |
---|---|---|
committer | Gavriel Fleischer <flocsy@gmail.com> | 2019-11-11 00:26:01 +0200 |
commit | 61d07a123beeaa1e85f44046413a680aabda0c9c (patch) | |
tree | 491cfef82314c5cf22861b1004b73ec4ad7d0854 /src/main | |
parent | 8a696af4d92821ccf741c21dcbe118861008743a (diff) | |
download | traccar-server-61d07a123beeaa1e85f44046413a680aabda0c9c.tar.gz traccar-server-61d07a123beeaa1e85f44046413a680aabda0c9c.tar.bz2 traccar-server-61d07a123beeaa1e85f44046413a680aabda0c9c.zip |
fixed NPE for optional language parameter
Diffstat (limited to 'src/main')
-rw-r--r-- | src/main/java/org/traccar/StringProtocolEncoder.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/main/java/org/traccar/StringProtocolEncoder.java b/src/main/java/org/traccar/StringProtocolEncoder.java index 40dfb25b6..e9fb65500 100644 --- a/src/main/java/org/traccar/StringProtocolEncoder.java +++ b/src/main/java/org/traccar/StringProtocolEncoder.java @@ -39,7 +39,7 @@ public abstract class StringProtocolEncoder extends BaseProtocolEncoder { if (valueFormatter != null) { value = valueFormatter.formatValue(keys[i], object); } - if (value == null) { + if (value == null && object != null) { value = object.toString(); } if (value == null) { |