diff options
author | Ville Skyttä <ville.skytta@iki.fi> | 2016-06-04 11:52:42 +0300 |
---|---|---|
committer | Ville Skyttä <ville.skytta@iki.fi> | 2016-06-04 11:52:42 +0300 |
commit | 9ab2d20427c67a2a2aadb4aeaa6fe046012edd65 (patch) | |
tree | e1880de5d6ccc1a34ed0ab757de11afb2e885227 /lib/sqlalchemy/dialects/postgresql | |
parent | 991346d5bbc29479c6c500c3f2b64fd6cc2e9a39 (diff) | |
download | sqlalchemy-pr/280.tar.gz |
Replace some uses of re.sub with str.lstrip/replacepr/280
Diffstat (limited to 'lib/sqlalchemy/dialects/postgresql')
-rw-r--r-- | lib/sqlalchemy/dialects/postgresql/base.py | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lib/sqlalchemy/dialects/postgresql/base.py b/lib/sqlalchemy/dialects/postgresql/base.py index 1bc4409f2..e25ec9aea 100644 --- a/lib/sqlalchemy/dialects/postgresql/base.py +++ b/lib/sqlalchemy/dialects/postgresql/base.py @@ -2085,7 +2085,7 @@ class PGDialect(default.DefaultDialect): attype = re.sub(r'\(.*\)', '', format_type) # strip '[]' from integer[], etc. - attype = re.sub(r'\[\]', '', attype) + attype = attype.replace('[]', '') nullable = not notnull is_array = format_type.endswith('[]') |