Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
model_name = 'thread'
verbose_name = 'thread'
verbose_name_raw = 'thread'
verbose_name_plural = 'threads'
object_name = 'thread'
default_related_name = None
_gmail_pk_field = 'id'
_gmail_fields = {
'id': GmailAutoField(),
'to': CharField(max_length=200),
'number_of_messages': CharField(max_length=200),
}
class MessageOptions(GmailOptions):
app_label = 'mailchecker'
model_name = 'message'
verbose_name = 'message'
verbose_name_raw = 'message'
verbose_name_plural = 'messages'
object_name = 'message'
default_related_name = None
_gmail_pk_field = 'id'
_gmail_fields = {
'id': GmailAutoField(),
'receiver': CharField(max_length=200),
'sender': CharField(max_length=200),
'snippet': CharField(max_length=200),
'body': TextField(),
}
field for field_name, field in
sorted(list(self._gmail_fields.items()) +
list(self._gmail_other_fields.items()))
)
def get_field(self, field_name):
try:
return self._gmail_fields[field_name]
except KeyError:
try:
return self._gmail_other_fields[field_name]
except KeyError:
raise FieldDoesNotExist()
class ThreadOptions(GmailOptions):
auto_created = False
app_label = 'mailchecker'
model_name = 'thread'
verbose_name = 'thread'
verbose_name_raw = 'thread'
verbose_name_plural = 'threads'
object_name = 'thread'
default_related_name = None
_gmail_pk_field = 'id'
_gmail_fields = {
'id': GmailAutoField(),
'to': CharField(max_length=200),
'number_of_messages': CharField(max_length=200),
}