from django.db import migrations, models
import encrypted_model_fields.fields


class Migration(migrations.Migration):
    """
    The reCAPTCHA v2 pair, so the last two keys can leave .env.

    v3 already lived in Settings. v2 is the fallback shown when a v3 score
    comes back low, and its secret was still being read from the file on
    disk. Additive, both blank by default.
    """

    dependencies = [
        ('pages', '0038_sitesettings_support_mailbox'),
    ]

    operations = [
        migrations.AddField(
            model_name='sitesettings',
            name='recaptcha_v2_site_key',
            field=models.CharField(blank=True, help_text='Google reCAPTCHA v2 site key, used for the fallback checkbox', max_length=100),
        ),
        migrations.AddField(
            model_name='sitesettings',
            name='recaptcha_v2_secret_key',
            field=encrypted_model_fields.fields.EncryptedCharField(blank=True, help_text='Google reCAPTCHA v2 secret key, stored encrypted', max_length=200),
        ),
    ]
