Skip to content

Commit 8993697

Browse files
committed
fix(src/lib/nodes/abstract.node.ts): temporaly consider node offline if health check fails
1 parent 100cc3f commit 8993697

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

src/lib/nodes/abstract.node.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -185,7 +185,11 @@ export abstract class Node<C = unknown> {
185185
`[HealthCheck] Alternative IP is not defined for ${this.getBaseURL(this)}. Node is offline.`,
186186
)
187187
}
188-
if (!this.healthcheckCount) this.preferDomain = false
188+
if (this.healthcheckCount < 1) {
189+
this.preferDomain = false
190+
} else {
191+
this.online = false
192+
}
189193
} else {
190194
if (protocol === 'https:' || this.isHttpAllowed(protocol)) this.online = false
191195

0 commit comments

Comments
 (0)