aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/org/traccar/reports
diff options
context:
space:
mode:
authorAnton Tananaev <anton@traccar.org>2023-06-11 08:10:16 -0700
committerAnton Tananaev <anton@traccar.org>2023-06-11 08:10:16 -0700
commit7f2ded68ef015684f90bef59c055a1c980688069 (patch)
tree5cfc06788da1d5fbbc0a1175b42185d9043e7e38 /src/main/java/org/traccar/reports
parentdf96f168eb4439beb044d301bcbf96502df62151 (diff)
downloadtrackermap-server-7f2ded68ef015684f90bef59c055a1c980688069.tar.gz
trackermap-server-7f2ded68ef015684f90bef59c055a1c980688069.tar.bz2
trackermap-server-7f2ded68ef015684f90bef59c055a1c980688069.zip
Clean up formatting
Diffstat (limited to 'src/main/java/org/traccar/reports')
-rw-r--r--src/main/java/org/traccar/reports/RouteReportProvider.java6
1 files changed, 4 insertions, 2 deletions
diff --git a/src/main/java/org/traccar/reports/RouteReportProvider.java b/src/main/java/org/traccar/reports/RouteReportProvider.java
index a1d004dd1..5343652b7 100644
--- a/src/main/java/org/traccar/reports/RouteReportProvider.java
+++ b/src/main/java/org/traccar/reports/RouteReportProvider.java
@@ -50,6 +50,7 @@ public class RouteReportProvider {
private final Config config;
private final ReportUtils reportUtils;
private final Storage storage;
+
private final Map<String, Integer> namesCount = new HashMap<>();
@Inject
@@ -72,9 +73,10 @@ public class RouteReportProvider {
private String getUniqueSheetName(String key) {
- namesCount.compute(key, (k, value) -> (value == null) ? 1 : (value + 1));
- return (namesCount.get(key) > 1 ? key + "-" + namesCount.get(key) : key);
+ namesCount.compute(key, (k, value) -> value == null ? 1 : (value + 1));
+ return namesCount.get(key) > 1 ? key + '-' + namesCount.get(key) : key;
}
+
public void getExcel(OutputStream outputStream,
long userId, Collection<Long> deviceIds, Collection<Long> groupIds,
Date from, Date to) throws StorageException, IOException {