chore: disable channel when error message contain credit or balance
This commit is contained in:
parent
1994256bac
commit
76569bb0b6
@ -49,6 +49,12 @@ func ShouldDisableChannel(err *relaymodel.Error, statusCode int) bool {
|
|||||||
if strings.Contains(err.Message, "quota") {
|
if strings.Contains(err.Message, "quota") {
|
||||||
return true
|
return true
|
||||||
}
|
}
|
||||||
|
if strings.Contains(err.Message, "credit") {
|
||||||
|
return true
|
||||||
|
}
|
||||||
|
if strings.Contains(err.Message, "balance") {
|
||||||
|
return true
|
||||||
|
}
|
||||||
return false
|
return false
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user