From 5118f5e281de16f5b17d147da462b6cfb16e4d4d Mon Sep 17 00:00:00 2001 From: soshial Date: Mon, 4 Oct 2021 18:58:02 +0200 Subject: fix Json decoding error (OpenCellId) --- .../java/org/traccar/geolocation/OpenCellIdGeolocationProvider.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'src/main/java/org') diff --git a/src/main/java/org/traccar/geolocation/OpenCellIdGeolocationProvider.java b/src/main/java/org/traccar/geolocation/OpenCellIdGeolocationProvider.java index 3b64a9a14..2535970d3 100644 --- a/src/main/java/org/traccar/geolocation/OpenCellIdGeolocationProvider.java +++ b/src/main/java/org/traccar/geolocation/OpenCellIdGeolocationProvider.java @@ -50,7 +50,7 @@ public class OpenCellIdGeolocationProvider implements GeolocationProvider { json.getJsonNumber("lon").doubleValue(), 0); } else { if (json.containsKey("error")) { - String errorMessage = json.getJsonString("error").getString(); + String errorMessage = json.getString("error"); if (json.containsKey("code")) { errorMessage += " (" + json.getInt("code") + ")"; } -- cgit v1.2.3