# Generated by Django 2.1.11 on 2019-10-07 14:56

from django.db import migrations, models

def set_extension_editable(apps, schema_editor):
    Extension = apps.get_model('editor','extension')
    for e in Extension.objects.all():
        if not e.zipfile:
            e.editable = False
            e.save()

class Migration(migrations.Migration):

    dependencies = [
        ('editor', '0038_auto_20190321_0932'),
    ]

    operations = [
        migrations.AddField(
            model_name='extension',
            name='editable',
            field=models.BooleanField(default=True, help_text="Is this extension stored within the editor's media folder?"),
        ),
        migrations.RunPython(set_extension_editable, migrations.RunPython.noop),
    ]
