Skip to content

Commit 50ef711

Browse files
authored
Merge pull request #1226 from tomguluson92/patch-2
fix: CircuitBreaker.ts
2 parents 21c63c4 + bb5caa5 commit 50ef711

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/core/src/database/CircuitBreaker.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ export class CircuitBreaker {
5353
this.failureCount++;
5454
this.lastFailureTime = Date.now();
5555

56-
if (this.failureCount >= this.failureThreshold) {
56+
if (this.state !== "OPEN" && this.failureCount >= this.failureThreshold) {
5757
this.state = "OPEN";
5858
}
5959
}

0 commit comments

Comments
 (0)