mirror of
https://github.com/EasyTier/EasyTier.git
synced 2026-10-08 19:06:14 -08:00
🐞 fix: GUI relay display error (#335)
This commit is contained in:
1 parent
9b28ecde8e
commit
cfe4d080d5
1 file changed
+2
-4
@@ -40,13 +40,11 @@ const peerRouteInfos = computed(() => {
|
||||
})
|
||||
|
||||
function routeCost(info: any) {
|
||||
if (!info.peer)
|
||||
return t('status.local')
|
||||
|
||||
if (info.route) {
|
||||
const cost = info.route.cost
|
||||
return cost === 1 ? 'p2p' : `relay(${cost})`
|
||||
return cost ? cost === 1 ? 'p2p' : `relay(${cost})` : t('status.local')
|
||||
}
|
||||
|
||||
return '?'
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user