Consider an exception or warning if null is passed into equality predicate

Description

Consider the following if the summaryAccount variable is null in a JPA Criteria Query.

and

Will produce different results. Granted the user should have used isNull but this allows a user to shoot themselves in the foot without knowing it. It would be helpful if this ideally threw an exception or at a minimum logged a warning.

Also see: https://gist.github.com/codylerum/6851dd5882b0d306fcea323a7cfe31e0

Environment

None

Activity

Show:
Cody Lerum
March 5, 2018, 9:52 PM

Related to

Assignee

Unassigned

Reporter

Cody Lerum

Fix versions

None

Labels

None

backPortable

None

Suitable for new contributors

None

Requires Release Note

None

Pull Request

None

backportDecision

None

Components

Affects versions

Priority

Major
Configure