Fix: GraphQL _or operator not working (#5840)

This commit is contained in:
Antonio Davi Macedo Coelho de Castro
2019-07-23 06:29:38 -07:00
committed by Douglas Muraoka
parent 5398b6f667
commit b605638415
2 changed files with 39 additions and 1 deletions

View File

@@ -119,7 +119,7 @@ const validateQuery = (
*/
Object.keys(query).forEach(key => {
const noCollisions = !query.$or.some(subq =>
subq.hasOwnProperty(key)
Object.hasOwnProperty.call(subq, key)
);
let hasNears = false;
if (query[key] != null && typeof query[key] == 'object') {