"""Add timestamp to messages

Revision ID: 7d9a9a4d50d7
Revises: bb5a68cd3f8e
Create Date: 2020-07-30 21:05:31.860934

"""
from alembic import op
import sqlalchemy as sa


# revision identifiers, used by Alembic.
revision = '7d9a9a4d50d7'
down_revision = 'bb5a68cd3f8e'
branch_labels = None
depends_on = None


def upgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    with op.batch_alter_table('message', schema=None) as batch_op:
        batch_op.add_column(sa.Column('date', sa.DateTime(timezone=True), nullable=True))

    # ### end Alembic commands ###


def downgrade():
    # ### commands auto generated by Alembic - please adjust! ###
    with op.batch_alter_table('message', schema=None) as batch_op:
        batch_op.drop_column('date')

    # ### end Alembic commands ###
