添加一个CheckErrs字典

This commit is contained in:
shadow1ng
2021-05-13 18:06:14 +08:00
parent 79aa24fc8f
commit 93245a16d0
3 changed files with 3 additions and 2 deletions
+1
View File
@@ -72,6 +72,7 @@ func CheckErrs(err error) bool {
"no pg_hba.conf entry",
"no supported methods remain",
"No connection could be made",
"invalid packet size",
}
for _, key := range errs {
if strings.Contains(strings.ToLower(err.Error()), strings.ToLower(key)) {