aboutsummaryrefslogtreecommitdiff
path: root/src/main
diff options
context:
space:
mode:
authorAnton Tananaev <anton@traccar.org>2023-10-16 07:28:26 -0700
committerAnton Tananaev <anton@traccar.org>2023-10-16 07:28:26 -0700
commit33d01cda7bb678bb604404f18c8f4e66a40eaa55 (patch)
treed73bcc8f923eba6655664450529e1b13df48b744 /src/main
parent6cf0435a85918b15a74014da20a151f971e9e43b (diff)
downloadtrackermap-server-33d01cda7bb678bb604404f18c8f4e66a40eaa55.tar.gz
trackermap-server-33d01cda7bb678bb604404f18c8f4e66a40eaa55.tar.bz2
trackermap-server-33d01cda7bb678bb604404f18c8f4e66a40eaa55.zip
Negative signal strength value
Diffstat (limited to 'src/main')
-rw-r--r--src/main/java/org/traccar/model/CellTower.java2
-rw-r--r--src/main/java/org/traccar/model/WifiAccessPoint.java2
2 files changed, 2 insertions, 2 deletions
diff --git a/src/main/java/org/traccar/model/CellTower.java b/src/main/java/org/traccar/model/CellTower.java
index 355594c64..4277cc4c4 100644
--- a/src/main/java/org/traccar/model/CellTower.java
+++ b/src/main/java/org/traccar/model/CellTower.java
@@ -104,7 +104,7 @@ public class CellTower {
}
public void setSignalStrength(Integer signalStrength) {
- this.signalStrength = signalStrength;
+ this.signalStrength = signalStrength > 0 ? -signalStrength : signalStrength;
}
public void setOperator(long operator) {
diff --git a/src/main/java/org/traccar/model/WifiAccessPoint.java b/src/main/java/org/traccar/model/WifiAccessPoint.java
index e28c1b935..64858f4c7 100644
--- a/src/main/java/org/traccar/model/WifiAccessPoint.java
+++ b/src/main/java/org/traccar/model/WifiAccessPoint.java
@@ -52,7 +52,7 @@ public class WifiAccessPoint {
}
public void setSignalStrength(Integer signalStrength) {
- this.signalStrength = signalStrength;
+ this.signalStrength = signalStrength > 0 ? -signalStrength : signalStrength;
}
private Integer channel;