Swirrl / grafter

Linked Data & RDF Manufacturing Tools in Clojure
Eclipse Public License 1.0
188 stars 17 forks source link

Boolean false values bindings in queries are rejected. #177

Closed danmidwood closed 3 years ago

danmidwood commented 3 years ago

Trying to bind a boolean value in a query works correctly when the value is true but does not work and throws an exception when the value is false.

The source of the exception:

https://github.com/Swirrl/grafter/blob/69ab1319612a802db25c5b0e2531f8a19b586594/src/grafter_2/rdf4j/sparql.clj#L240-L243

It is the val that is checked in the condition that fails when it is false. We should prevent nil values from being passed through but falses are still valid.