import peewee as pw


def migrate(migrator, database, fake=False, **kwargs):
    IPList = migrator.orm["iplist"]
    migrator.add_fields(
        IPList, dos_expiration=pw.IntegerField(default=0, null=True)
    )


def rollback(migrator, database, fake=False, **kwargs):
    IPList = migrator.orm["iplist"]
    migrator.remove_fields(IPList, "dos_expiration")
