mirror of
https://github.com/ent/ent.git
synced 2026-05-24 09:31:56 +03:00
entc/gen: fix missing unique field in query builder template (#2332)
* fix(query): fix missing unique field in query builder template when a query gets cloned the unique field doesn't get cloned #2331 * fix(query): added missing go generate ./... #2331 * fix(query): added missing go generate ./... #2331
This commit is contained in:
@@ -273,8 +273,9 @@ func (cq *CardQuery) Clone() *CardQuery {
|
||||
predicates: append([]predicate.Card{}, cq.predicates...),
|
||||
withOwner: cq.withOwner.Clone(),
|
||||
// clone intermediate query.
|
||||
sql: cq.sql.Clone(),
|
||||
path: cq.path,
|
||||
sql: cq.sql.Clone(),
|
||||
path: cq.path,
|
||||
unique: cq.unique,
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -273,8 +273,9 @@ func (uq *UserQuery) Clone() *UserQuery {
|
||||
predicates: append([]predicate.User{}, uq.predicates...),
|
||||
withCard: uq.withCard.Clone(),
|
||||
// clone intermediate query.
|
||||
sql: uq.sql.Clone(),
|
||||
path: uq.path,
|
||||
sql: uq.sql.Clone(),
|
||||
path: uq.path,
|
||||
unique: uq.unique,
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user