mirror of
https://github.com/zitadel/zitadel.git
synced 2025-08-23 16:20:29 +00:00
show tim
This commit is contained in:
@@ -72,6 +72,14 @@ type Querier interface {
|
||||
QueryRow(ctx context.Context, stmt string, args ...any) Row
|
||||
}
|
||||
|
||||
func Query[Out any](q Querier, fn func(q Querier) ([]Out, error)) ([]Out, error) {
|
||||
return fn(q)
|
||||
}
|
||||
|
||||
func QueryRow[Out any](q Querier, fn func(q Querier) (Out, error)) (Out, error) {
|
||||
return fn(q)
|
||||
}
|
||||
|
||||
type Executor interface {
|
||||
Exec(ctx context.Context, stmt string, args ...any) error
|
||||
}
|
||||
|
Reference in New Issue
Block a user