diff options
author | Anton Tananaev <anton@traccar.org> | 2023-01-31 15:25:18 -0800 |
---|---|---|
committer | Anton Tananaev <anton@traccar.org> | 2023-01-31 15:25:18 -0800 |
commit | 21991edfc7c67bd3e27998f06473d211b6685c6c (patch) | |
tree | cfbabd7c4d61691ffb3f3d8d3a9eaa917e6b282b /modern/src/main/MainToolbar.js | |
parent | dcb1fa21441cb292fd66253a97b083e5d47604e5 (diff) | |
download | trackermap-web-21991edfc7c67bd3e27998f06473d211b6685c6c.tar.gz trackermap-web-21991edfc7c67bd3e27998f06473d211b6685c6c.tar.bz2 trackermap-web-21991edfc7c67bd3e27998f06473d211b6685c6c.zip |
Handle readonly cases
Diffstat (limited to 'modern/src/main/MainToolbar.js')
-rw-r--r-- | modern/src/main/MainToolbar.js | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/modern/src/main/MainToolbar.js b/modern/src/main/MainToolbar.js index caba2410..b029529c 100644 --- a/modern/src/main/MainToolbar.js +++ b/modern/src/main/MainToolbar.js @@ -167,7 +167,7 @@ const MainToolbar = ({ </div> </Popover> <IconButton edge="end" onClick={() => navigate('/settings/device')} disabled={deviceReadonly}> - <Tooltip open={Object.keys(devices).length === 0} title={t('deviceRegisterFirst')} arrow> + <Tooltip open={!deviceReadonly && Object.keys(devices).length === 0} title={t('deviceRegisterFirst')} arrow> <AddIcon /> </Tooltip> </IconButton> |