Customizable msg posting timeout and msg length

This commit is contained in:
Jeremy Zhang
2018-03-25 04:43:39 +00:00
parent 18f25d0852
commit e8424a63c8
11 changed files with 116 additions and 5 deletions

View File

@ -0,0 +1,30 @@
"""Add post_timeout and max_message_length columns to guilds
Revision ID: 176d26252734
Revises: b18fcc759865
Create Date: 2018-03-25 04:04:11.000997
"""
# revision identifiers, used by Alembic.
revision = '176d26252734'
down_revision = 'b18fcc759865'
branch_labels = None
depends_on = None
from alembic import op
import sqlalchemy as sa
def upgrade():
# ### commands auto generated by Alembic - please adjust! ###
op.add_column('guilds', sa.Column('max_message_length', sa.Integer(), server_default='300', nullable=False))
op.add_column('guilds', sa.Column('post_timeout', sa.Integer(), server_default='5', nullable=False))
# ### end Alembic commands ###
def downgrade():
# ### commands auto generated by Alembic - please adjust! ###
op.drop_column('guilds', 'post_timeout')
op.drop_column('guilds', 'max_message_length')
# ### end Alembic commands ###