"""removed unique constraint from venue name and instead added an index

Revision ID: 18f95f69199b
Revises: ab9ecb88d7c1
Create Date: 2020-03-28 16:10:12.874407

"""
from alembic import op
import sqlalchemy as sa


# revision identifiers, used by Alembic.
revision = '18f95f69199b'
down_revision = 'ab9ecb88d7c1'
branch_labels = None
depends_on = None


def upgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.create_index(op.f('ix_venues_name'), 'venues', ['name'], unique=False)
    op.drop_constraint('venues_name_key', 'venues', type_='unique')
    # ### end Alembic commands ###


def downgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.create_unique_constraint('venues_name_key', 'venues', ['name'])
    op.drop_index(op.f('ix_venues_name'), table_name='venues')
    # ### end Alembic commands ###
