<commit_before>@validateArgument = (argumentValue, match, argumentName) ->
  throw new Error "Argument name not set." unless argumentName
  try
    check argumentValue, match
  catch error
    throw new ValidationError error.message, argumentName

class @ValidationError extends Meteor.Error
  constructor: (reason, argumentName) ->
    error = 400
    details = "Argument: #{ argumentName or '' }" if argumentName
    super error, reason, details
<commit_msg>Using assert to check ValidationError argumentName.<commit_after>@validateArgument = (argumentValue, match, argumentName) ->
  throw new Error "Argument name not set." unless argumentName
  try
    check argumentValue, match
  catch error
    throw new ValidationError error.message, argumentName

class @ValidationError extends Meteor.Error
  constructor: (reason, argumentName) ->
    assert argumentName
    error = 400
    details = "Argument: #{ argumentName }"
    super error, reason, details

{'fraction_non_alphanumeric': 0.07604166666666666, 'fraction_numerical': 0.00625, 'mean_word_length': 4.368715083798882, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '461901', 'n_tokens_mistral': 247, 'n_tokens_neox': 237, 'n_words': 90}