Browse Source
Merge pull request #430 from PhotoNomad0/bugfix-fixMapCrashHwModel
bugfix for Map crash
pull/434/head
Dan Ditomaso
1 year ago
committed by
GitHub
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
1 changed files with
3 additions and
3 deletions
-
src/components/PageComponents/Map/NodeDetail.tsx
|
|
|
@ -26,9 +26,9 @@ export interface NodeDetailProps { |
|
|
|
|
|
|
|
export const NodeDetail = ({ node }: NodeDetailProps) => { |
|
|
|
const name = node.user?.longName || `!${numberToHexUnpadded(node.num)}`; |
|
|
|
const hardwareType = Protobuf.Mesh.HardwareModel[ |
|
|
|
node.user?.hwModel ?? 0 |
|
|
|
].replaceAll("_", " "); |
|
|
|
const hwModel = node.user?.hwModel ?? 0; |
|
|
|
const hardwareType = |
|
|
|
Protobuf.Mesh.HardwareModel[hwModel]?.replaceAll("_", " ") ?? `${hwModel}`; |
|
|
|
|
|
|
|
return ( |
|
|
|
<div className="dark:text-black p-1"> |
|
|
|
|