"""empty message

Revision ID: d5c46b637928
Revises: 
Create Date: 2020-09-21 09:57:00.984941

"""
from alembic import op
import sqlalchemy as sa


# revision identifiers, used by Alembic.
revision = "d5c46b637928"
down_revision = None
branch_labels = None
depends_on = None


def upgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.create_table(
        "links",
        sa.Column("id", sa.Integer(), nullable=False),
        sa.Column("link", sa.String(length=150), nullable=True),
        sa.Column("token", sa.String(length=20), nullable=True),
        sa.Column("visits", sa.Integer(), nullable=True),
        sa.PrimaryKeyConstraint("id"),
    )
    op.create_index(op.f("ix_links_token"), "links", ["token"], unique=False)
    # ### end Alembic commands ###


def downgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.drop_index(op.f("ix_links_token"), table_name="links")
    op.drop_table("links")
    # ### end Alembic commands ###
