diff options
Diffstat (limited to 'modern/src/main')
-rw-r--r-- | modern/src/main/DevicesList.js | 9 |
1 files changed, 4 insertions, 5 deletions
diff --git a/modern/src/main/DevicesList.js b/modern/src/main/DevicesList.js index fe963124..057ae28d 100644 --- a/modern/src/main/DevicesList.js +++ b/modern/src/main/DevicesList.js @@ -75,12 +75,11 @@ const DeviceRow = ({ data, index, style }) => { const position = useSelector((state) => state.positions.items[item.id]); const secondaryText = () => { - const status = formatStatus(item.status, t); - if (item.lastUpdate) { - const lastUpdate = moment(item.lastUpdate).fromNow(); - return `${status} ${lastUpdate}`; + if (item.status === 'online' || !item.lastUpdate) { + return formatStatus(item.status, t); + } else { + return moment(item.lastUpdate).fromNow(); } - return status; }; return ( |