summaryrefslogtreecommitdiff
path: root/vendor/github.com/uptrace/bun/dialect/pgdialect/inspector.go
diff options
context:
space:
mode:
authorLibravatar kim <89579420+NyaaaWhatsUpDoc@users.noreply.github.com>2025-01-14 14:23:28 +0000
committerLibravatar GitHub <noreply@github.com>2025-01-14 14:23:28 +0000
commitb8ef9fc4bcccc6c024edaa8e9c91a6bf87f83dd9 (patch)
tree68eaf966c80237e18993e887c8583355f0943ca7 /vendor/github.com/uptrace/bun/dialect/pgdialect/inspector.go
parent[chore] better dns validation (#3644) (diff)
downloadgotosocial-b8ef9fc4bcccc6c024edaa8e9c91a6bf87f83dd9.tar.xz
bump uptrace/bun dependencies from 1.2.6 to 1.2.8 (#3645)
Diffstat (limited to 'vendor/github.com/uptrace/bun/dialect/pgdialect/inspector.go')
-rw-r--r--vendor/github.com/uptrace/bun/dialect/pgdialect/inspector.go10
1 files changed, 5 insertions, 5 deletions
diff --git a/vendor/github.com/uptrace/bun/dialect/pgdialect/inspector.go b/vendor/github.com/uptrace/bun/dialect/pgdialect/inspector.go
index 42bbbe84f..040df439c 100644
--- a/vendor/github.com/uptrace/bun/dialect/pgdialect/inspector.go
+++ b/vendor/github.com/uptrace/bun/dialect/pgdialect/inspector.go
@@ -5,8 +5,8 @@ import (
"strings"
"github.com/uptrace/bun"
+ "github.com/uptrace/bun/internal/ordered"
"github.com/uptrace/bun/migrate/sqlschema"
- orderedmap "github.com/wk8/go-ordered-map/v2"
)
type (
@@ -34,7 +34,7 @@ func newInspector(db *bun.DB, options ...sqlschema.InspectorOption) *Inspector {
func (in *Inspector) Inspect(ctx context.Context) (sqlschema.Database, error) {
dbSchema := Schema{
- Tables: orderedmap.New[string, sqlschema.Table](),
+ Tables: ordered.NewMap[string, sqlschema.Table](),
ForeignKeys: make(map[sqlschema.ForeignKey]string),
}
@@ -61,7 +61,7 @@ func (in *Inspector) Inspect(ctx context.Context) (sqlschema.Database, error) {
return dbSchema, err
}
- colDefs := orderedmap.New[string, sqlschema.Column]()
+ colDefs := ordered.NewMap[string, sqlschema.Column]()
uniqueGroups := make(map[string][]string)
for _, c := range columns {
@@ -72,7 +72,7 @@ func (in *Inspector) Inspect(ctx context.Context) (sqlschema.Database, error) {
def = strings.ToLower(def)
}
- colDefs.Set(c.Name, &Column{
+ colDefs.Store(c.Name, &Column{
Name: c.Name,
SQLType: c.DataType,
VarcharLen: c.VarcharLen,
@@ -103,7 +103,7 @@ func (in *Inspector) Inspect(ctx context.Context) (sqlschema.Database, error) {
}
}
- dbSchema.Tables.Set(table.Name, &Table{
+ dbSchema.Tables.Store(table.Name, &Table{
Schema: table.Schema,
Name: table.Name,
Columns: colDefs,