"""added followers users

Revision ID: a5384475dbb8
Revises: d0b8133f3d63
Create Date: 2018-03-29 21:01:31.363223

"""
from alembic import op
import sqlalchemy as sa


# revision identifiers, used by Alembic.
revision = 'a5384475dbb8'
down_revision = 'd0b8133f3d63'
branch_labels = None
depends_on = None


def upgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.create_table('followers',
    sa.Column('follower_id', sa.Integer(), nullable=True),
    sa.Column('followed_id', sa.Integer(), nullable=True),
    sa.ForeignKeyConstraint(['followed_id'], ['user.uid'], ),
    sa.ForeignKeyConstraint(['follower_id'], ['user.uid'], )
    )
    op.drop_table('user_followers')
    # ### end Alembic commands ###


def downgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    op.create_table('user_followers',
    sa.Column('follower_id', sa.INTEGER(), nullable=True),
    sa.Column('followed_id', sa.INTEGER(), nullable=True),
    sa.ForeignKeyConstraint(['followed_id'], ['user.uid'], ),
    sa.ForeignKeyConstraint(['follower_id'], ['user.uid'], )
    )
    op.drop_table('followers')
    # ### end Alembic commands ###
