mirror of
https://github.com/coleifer/peewee.git
synced 2026-05-06 07:56:41 -04:00
Resolve regex library warnings
Signed-off-by: Emmanuel Ferdman <emmanuelferdman@gmail.com>
This commit is contained in:
@@ -912,7 +912,7 @@ class SqliteMigrator(SchemaMigrator):
|
||||
@operation
|
||||
def drop_column_default(self, table, column):
|
||||
def _drop_default(column_name, column_def):
|
||||
col = re.sub(r'DEFAULT\s+[\w"\'\(\)]+(\s|$)', '', column_def, re.I)
|
||||
col = re.sub(r'DEFAULT\s+[\w"\'\(\)]+(\s|$)', '', column_def, flags=re.I)
|
||||
return col.strip()
|
||||
return self._update_column(table, column, _drop_default)
|
||||
|
||||
|
||||
Reference in New Issue
Block a user