Skip to content

Commit

Permalink
fix: incorrect url formatting for localhost on coin nodes
Browse files Browse the repository at this point in the history
  • Loading branch information
aineo committed Jun 28, 2024
1 parent d58889d commit feb0b74
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions src/components/nodes/components/NodeUrl.vue
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,9 @@

<template v-else>
<span :class="classes.nodeName">{{ nodeHost.name }}</span>
<span :class="classes.domain">.{{ nodeHost.domain }}</span>
<span v-if="nodeHost.domain && nodeHost.domain.length > 0" :class="classes.domain"
>.{{ nodeHost.domain }}</span
>
</template>

<span v-if="port" :class="classes.port">:{{ port }}</span>
Expand Down Expand Up @@ -43,7 +45,7 @@ export default {
let domain = null
if (!isIP.value) {
const regex = /([^.]*)\.(.*)/
const regex = /([^.]*)\.?(.*)/
const parts = hostname.value.match(regex)
if (parts !== null) {
name = parts[1]
Expand Down

0 comments on commit feb0b74

Please sign in to comment.