Skip to content

Commit

Permalink
Addressed merge comment
Browse files Browse the repository at this point in the history
  • Loading branch information
jordanVoss committed Oct 15, 2024
1 parent e8bf18f commit 8b816c0
Showing 1 changed file with 5 additions and 5 deletions.
10 changes: 5 additions & 5 deletions stix2validator/v21/shoulds.py
Original file line number Diff line number Diff line change
Expand Up @@ -387,7 +387,7 @@ def check_vocab(instance, vocab, code):

if not is_in:
vocab_name = vocab.replace('_', '-').lower()
yield JSONError("The value contained in %s is permitted, but is not in the %s-ov vocabulary. "
yield JSONError("The value contained in %s is permitted, but is not in the %s-ov "
"vocabulary." % (prop, vocab_name),
instance['id'], code)

Expand Down Expand Up @@ -531,17 +531,17 @@ def relationships_strict(instance):
return

if r_source not in enums.RELATIONSHIPS:
return JSONError("'%s' is permitted, but not a suggested relationship type for '%s' object "
return JSONError("'%s' is permitted, but not a suggested relationship source object "
"for the '%s' relationship." % (r_source, r_type),
instance['id'], 'relationship-types')

if r_type not in enums.RELATIONSHIPS[r_source]:
return JSONError("'%s' is permitted, but not a suggested relationship type for '%s' object "
return JSONError("'%s' is permitted, but not a suggested relationship type for '%s' "
"objects." % (r_type, r_source), instance['id'],
'relationship-types')

if r_target not in enums.RELATIONSHIPS[r_source][r_type]:
return JSONError("'%s' is permitted, but not a suggested relationship type for '%s' object "
return JSONError("'%s' is permitted, but not a suggested relationship target object "
"for '%s' objects with the '%s' relationship."
% (r_target, r_source, r_type), instance['id'],
'relationship-types')
Expand Down Expand Up @@ -1707,4 +1707,4 @@ def list_shoulds(options):
else:
validator_list.append(check_function)

return validator_list
return validator_list

0 comments on commit 8b816c0

Please sign in to comment.