Skip to content

CompositeExpression is mutable #3844

Closed
Closed
@morozov

Description

Q A
BC Break no
Version 2.10.1

If a composite expression is used in different parts of the same query or in different queries, its implicit mutation by the QueryBuilder::(and|or)(Where|Having)() methods in one place will affect the other places as well.

Before:

$expr->add('u.group_id = 2');

After:

$expr = $expr->with('u.group_id = 2');

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Assignees

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions