Skip to content

Commit ac6ef22

Browse files
author
Viktor Tochonov
committed
Fix OfTypes case for ObjectListFilter and Implemented new tests for OfTypes filter with differeny types quantity
1 parent 878a90a commit ac6ef22

File tree

3 files changed

+191
-39
lines changed

3 files changed

+191
-39
lines changed

src/FSharp.Data.GraphQL.Server.Middleware/ObjectListFilter.fs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -224,7 +224,7 @@ module ObjectListFilter =
224224
| OfTypes types ->
225225
types
226226
|> Seq.map (fun t -> buildTypeDiscriminatorCheck param t)
227-
|> Seq.reduce (fun acc expr -> Expression.Or (acc, expr))
227+
|> Seq.reduce (fun acc expr -> Expression.OrElse (acc, expr))
228228
| FilterField f ->
229229
let paramExpr = Expression.PropertyOrField (param, f.FieldName)
230230
buildFilterExpr (SourceExpression paramExpr) buildTypeDiscriminatorCheck f.Value

0 commit comments

Comments
 (0)