is it safe to create django-allauth confirmation email table manually?

27 Views Asked by At

I am building a web app using Django, and I am using Django-Allauth for the authentication. Somehow when I was inspecting the database in mysql workbench I though a saw a duplicate table named account_EmailConfirmation and before I think about it I dropped the table and both of them dropped. Idk exactly know why they appeared as 2 tables and when I dropped one the other was deleted but anyway, i decided then to create the table again manually.

    operations = [
    migrations.CreateModel(
        name='EmailConfirmation',
        fields=[
            ('id', models.AutoField(primary_key=True, auto_created=True, serialize=False, verbose_name='ID')),
            ('created', models.DateTimeField(auto_now_add=True)),
            ('sent', models.DateTimeField(null=True, blank=True)),
            ('key', models.CharField(max_length=64, unique=True)),
            ('email_address_id', models.ForeignKey(to='account.EmailAddress', on_delete=models.CASCADE)),
        ],
        options={
            'db_table': 'account_emailconfirmation',
        },
    ),
]

My question is this: Is this safe and okay to do, or is it going to cause issues later on?

0

There are 0 best solutions below