mirror of
https://github.com/EasyTier/EasyTier.git
synced 2025-10-06 01:06:51 +08:00
🐞 fix: GUI relay display error (#335)
This commit is contained in:
@@ -40,13 +40,11 @@ const peerRouteInfos = computed(() => {
|
|||||||
})
|
})
|
||||||
|
|
||||||
function routeCost(info: any) {
|
function routeCost(info: any) {
|
||||||
if (!info.peer)
|
|
||||||
return t('status.local')
|
|
||||||
|
|
||||||
if (info.route) {
|
if (info.route) {
|
||||||
const cost = info.route.cost
|
const cost = info.route.cost
|
||||||
return cost === 1 ? 'p2p' : `relay(${cost})`
|
return cost ? cost === 1 ? 'p2p' : `relay(${cost})` : t('status.local')
|
||||||
}
|
}
|
||||||
|
|
||||||
return '?'
|
return '?'
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user