@@ -275,9 +275,9 @@ def dependencies(validator, dependencies, instance, schema):
275
275
if property not in instance :
276
276
continue
277
277
278
- if dependency == True :
278
+ if dependency is True :
279
279
dependency = {}
280
- elif dependency == False :
280
+ elif dependency is False :
281
281
dependency = {"not" : {}}
282
282
283
283
if validator .is_type (dependency , "object" ):
@@ -433,9 +433,9 @@ def allOf_draft4(validator, allOf, instance, schema):
433
433
434
434
def allOf_draft6 (validator , allOf , instance , schema ):
435
435
for index , subschema in enumerate (allOf ):
436
- if subschema == True : # FIXME: Messages
436
+ if subschema is True : # FIXME: Messages
437
437
subschema = {}
438
- elif subschema == False :
438
+ elif subschema is False :
439
439
subschema = {"not" : {}}
440
440
for error in validator .descend (instance , subschema , schema_path = index ):
441
441
yield error
@@ -482,9 +482,9 @@ def anyOf_draft4(validator, anyOf, instance, schema):
482
482
def anyOf_draft6 (validator , anyOf , instance , schema ):
483
483
all_errors = []
484
484
for index , subschema in enumerate (anyOf ):
485
- if subschema == True : # FIXME: Messages
485
+ if subschema is True : # FIXME: Messages
486
486
subschema = {}
487
- elif subschema == False :
487
+ elif subschema is False :
488
488
subschema = {"not" : {}}
489
489
errs = list (validator .descend (instance , subschema , schema_path = index ))
490
490
if not errs :
0 commit comments