aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAnton Tananaev <anton@traccar.org>2023-11-26 07:05:39 -0800
committerAnton Tananaev <anton@traccar.org>2023-11-26 07:05:39 -0800
commitd90ec814f5b76ec9b733ac77b3c0ea1eb5e7570e (patch)
tree28ace661355cc88cf1540011cbcd4aeaa2aba17e
parent43e6573b86ae3d015fd082280e3692711caec9fb (diff)
downloadtrackermap-web-d90ec814f5b76ec9b733ac77b3c0ea1eb5e7570e.tar.gz
trackermap-web-d90ec814f5b76ec9b733ac77b3c0ea1eb5e7570e.tar.bz2
trackermap-web-d90ec814f5b76ec9b733ac77b3c0ea1eb5e7570e.zip
Fix missing driver issue (fix #1197)
-rw-r--r--modern/src/common/components/DriverValue.js2
1 files changed, 1 insertions, 1 deletions
diff --git a/modern/src/common/components/DriverValue.js b/modern/src/common/components/DriverValue.js
index 0969ca20..6148b418 100644
--- a/modern/src/common/components/DriverValue.js
+++ b/modern/src/common/components/DriverValue.js
@@ -3,7 +3,7 @@ import { useSelector } from 'react-redux';
const DriverValue = ({ driverUniqueId }) => {
const driver = useSelector((state) => state.drivers.items[driverUniqueId]);
- return driver.name;
+ return driver?.name || driverUniqueId;
};
export default DriverValue;