[CSHARP-1291] And and Or filter builder methods should handle zero clauses correctly Created: 21/May/15 Updated: 30/May/17 Resolved: 06/Jan/17 |
|
| Status: | Closed |
| Project: | C# Driver |
| Component/s: | API |
| Affects Version/s: | 2.0 |
| Fix Version/s: | 2.4.2 |
| Type: | Improvement | Priority: | Minor - P4 |
| Reporter: | Robert Stam | Assignee: | Robert Stam |
| Resolution: | Done | Votes: | 0 |
| Labels: | None | ||
| Remaining Estimate: | Not Specified | ||
| Time Spent: | Not Specified | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||||||||||
| Description |
|
The Filter builder And and Or methods should handle empty lists of clauses by rendering them to $and and $or operators with empty arrays:
It is not really obvious what semantics And and Or should have when the list of clauses is empty. By rendering them this way we leave it up to the server to decide. The server currently returns error messages for both of these, but it might conceivably support them in the future. |
| Comments |
| Comment by Githook User [ 06/Jan/17 ] |
|
Author: {u'username': u'rstam', u'name': u'rstam', u'email': u'robert@robertstam.org'}Message: |