feat(core): 下沉查询密码工具与配置快照解码
Verify / verify (push) Canceled after 0s

This commit is contained in:
zhangdeman committed 2026-11-28 03:10:18 -08:00
1 parent bedcf4dd83
commit d2a9033695
23 files changed
+1544 -6

No files matched your search

+17
View File
@@ -0,0 +1,17 @@
//go:build cgo
package dberror
import (
"errors"
"github.com/mattn/go-sqlite3"
)
// isSQLiteDuplicateKey 在启用CGO时识别SQLite驱动原因链;err为执行错误,返回是否唯一键或主键冲突。
func isSQLiteDuplicateKey(err error) bool {
var (
sqliteError sqlite3.Error
)
return errors.As(err, &sqliteError) && (sqliteError.ExtendedCode == sqlite3.ErrConstraintUnique || sqliteError.ExtendedCode == sqlite3.ErrConstraintPrimaryKey)
}
Reference in new issue
Block a user
Blocking a user prevents them from interacting with repositories, such as opening or commenting on pull requests or issues. Learn more about blocking a user.