@register.simple_tag
def check_name(check):
 try:
  return escape(CHECKS[check].name)
 except KeyError:
  return escape(check)

@ register . simple_tag def check_name ( check ) : try : return escape ( CHECKS [ check ] . name ) except KeyError : return escape ( check )
check whether the specified name contains invalid characters .