aboutsummaryrefslogtreecommitdiffstats
path: root/markdown
diff options
context:
space:
mode:
authorAdam Wood <adam.michael.wood@gmail.com>2016-10-26 10:17:38 -0700
committerWaylan Limberg <waylan.limberg@icloud.com>2016-10-26 13:17:38 -0400
commit0244474b2dbf15986891a8d700c7bb121dc6f55f (patch)
tree426f87e0814a05bb3989b2d8c08c5216b2dda84f /markdown
parent251183ef2817dcf09f502bea15423f6e81c5e228 (diff)
downloadmarkdown-0244474b2dbf15986891a8d700c7bb121dc6f55f.tar.gz
markdown-0244474b2dbf15986891a8d700c7bb121dc6f55f.tar.bz2
markdown-0244474b2dbf15986891a8d700c7bb121dc6f55f.zip
lists are not tables - fixes #478 (#507)
Diffstat (limited to 'markdown')
-rw-r--r--markdown/extensions/tables.py3
1 files changed, 2 insertions, 1 deletions
diff --git a/markdown/extensions/tables.py b/markdown/extensions/tables.py
index 8c11739..7c75507 100644
--- a/markdown/extensions/tables.py
+++ b/markdown/extensions/tables.py
@@ -30,7 +30,8 @@ class TableProcessor(BlockProcessor):
rows = block.split('\n')
return (len(rows) > 1 and '|' in rows[0] and
'|' in rows[1] and '-' in rows[1] and
- rows[1].strip()[0] in ['|', ':', '-'])
+ rows[1].strip()[0] in ['|', ':', '-'] and
+ set(rows[1]) <= set('|:- '))
def run(self, parent, blocks):
""" Parse a table block and build table. """