diff options
author | 2021-09-29 15:09:45 +0200 | |
---|---|---|
committer | 2021-09-29 15:09:45 +0200 | |
commit | 9a53b1a8d19da525ca7ace957b2d32f85dbe0fe9 (patch) | |
tree | 5f7a391618a0d1c68ab1f21ef4bd18ff034486ec /vendor/github.com/uptrace/bun/join.go | |
parent | skip account on error instead of returning error (#251) (diff) | |
download | gotosocial-9a53b1a8d19da525ca7ace957b2d32f85dbe0fe9.tar.xz |
upstep bun to v1.0.9 (#252)
Diffstat (limited to 'vendor/github.com/uptrace/bun/join.go')
-rw-r--r-- | vendor/github.com/uptrace/bun/join.go | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/vendor/github.com/uptrace/bun/join.go b/vendor/github.com/uptrace/bun/join.go index 42bf800d6..7d5ce06fc 100644 --- a/vendor/github.com/uptrace/bun/join.go +++ b/vendor/github.com/uptrace/bun/join.go @@ -10,8 +10,8 @@ import ( type relationJoin struct { Parent *relationJoin - BaseModel tableModel - JoinModel tableModel + BaseModel TableModel + JoinModel TableModel Relation *schema.Relation apply func(*SelectQuery) *SelectQuery @@ -71,8 +71,8 @@ func (j *relationJoin) manyQuery(q *SelectQuery) *SelectQuery { where = appendChildValues( q.db.Formatter(), where, - j.JoinModel.Root(), - j.JoinModel.ParentIndex(), + j.JoinModel.rootValue(), + j.JoinModel.parentIndex(), j.Relation.BaseFields, ) where = append(where, ")"...) @@ -135,7 +135,7 @@ func (j *relationJoin) m2mQuery(q *SelectQuery) *SelectQuery { } q = q.Model(m2mModel) - index := j.JoinModel.ParentIndex() + index := j.JoinModel.parentIndex() baseTable := j.BaseModel.Table() //nolint @@ -154,7 +154,7 @@ func (j *relationJoin) m2mQuery(q *SelectQuery) *SelectQuery { join = append(join, col.SQLName...) } join = append(join, ") IN ("...) - join = appendChildValues(fmter, join, j.BaseModel.Root(), index, baseTable.PKs) + join = appendChildValues(fmter, join, j.BaseModel.rootValue(), index, baseTable.PKs) join = append(join, ")"...) q = q.Join(internal.String(join)) |