downgrade()   A
last analyzed

Complexity

Conditions 2

Size

Total Lines 4
Code Lines 4

Duplication

Lines 0
Ratio 0 %

Importance

Changes 0
Metric Value
cc 2
eloc 4
nop 0
dl 0
loc 4
rs 10
c 0
b 0
f 0
1
"""remove webdav_right_digest_response_hash from database
2
3
Revision ID: 2b4043fa2502
4
Revises: f3852e1349c4
5
Create Date: 2018-03-13 14:41:38.590375
6
7
"""
8
9
# revision identifiers, used by Alembic.
10
revision = '2b4043fa2502'
11
down_revision = None
12
13
from alembic import op
14
from sqlalchemy import Column, Unicode
15
16
17
def upgrade():
18
    with op.batch_alter_table('users') as batch_op:
19
        batch_op.drop_column('webdav_left_digest_response_hash')
20
21
22
def downgrade():
23
    with op.batch_alter_table('users') as batch_op:
24
        batch_op.add_column(
25
            Column('webdav_left_digest_response_hash', Unicode(128))
26
        )
27