Skip to content

Commit

Permalink
Merge pull request #268 from KomelT/fix/hops-singular
Browse files Browse the repository at this point in the history
Fixed hops singular form
  • Loading branch information
Hunter275 authored Aug 6, 2024
2 parents 2528391 + 5771e1b commit cfc2ea0
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion src/pages/Nodes.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -75,7 +75,9 @@ export const NodesPage = (): JSX.Element => {
{node.lastHeard !== 0
? node.viaMqtt === false && node.hopsAway === 0
? "Direct"
: `${node.hopsAway.toString()} hops away`
: `${node.hopsAway.toString()} ${
node.hopsAway > 1 ? "hops" : "hop"
} away`
: "-"}
{node.viaMqtt === true ? ", via MQTT" : ""}
</Mono>,
Expand Down

0 comments on commit cfc2ea0

Please sign in to comment.