  def check_string_if_invalid_is_string(app_configs, **kwargs):
      errors = []
      for conf in settings.TEMPLATES:
          string_if_invalid = conf.get('OPTIONS', {}).get('string_if_invalid', '')
          if not isinstance(string_if_invalid, six.string_types):
              error = copy.copy(E002)
              error.msg = error.msg.format(string_if_invalid, type(string_if_invalid).__name__)
              errors.append(error)
      return errors
 
</s> remove         if isinstance(self.remote_field.model, six.string_types):
 </s> add         if isinstance(self.remote_field.model, str): </s> remove         if isinstance(self.remote_field.through, six.string_types) or not self.remote_field.through._meta.managed:
 </s> add         if isinstance(self.remote_field.through, str) or not self.remote_field.through._meta.managed: </s> remove         rel_is_string = isinstance(self.remote_field.model, six.string_types)
 </s> add         rel_is_string = isinstance(self.remote_field.model, str) </s> remove         rel_is_string = isinstance(self.remote_field.model, six.string_types)
 </s> add         rel_is_string = isinstance(self.remote_field.model, str) </s> remove             if isinstance(r, six.string_types):
 </s> add             if isinstance(r, str):
        if not isinstance(string_if_invalid, str):
  def check_string_if_invalid_is_string(app_configs, **kwargs):
      errors = []
      for conf in settings.TEMPLATES:
          string_if_invalid = conf.get('OPTIONS', {}).get('string_if_invalid', '')
        if not isinstance(string_if_invalid, str):
              error = copy.copy(E002)
              error.msg = error.msg.format(string_if_invalid, type(string_if_invalid).__name__)
              errors.append(error)
      return errors
keep keep keep keep replace keep keep keep keep
 Refs #23919 -- Removed six.<various>_types usage

Thanks Tim Graham and Simon Charette for the reviews. 
django/core/checks/templates.py