Simplify regex for relative size

This commit is contained in:
Juda Kaleta 2014-03-07 22:24:23 +01:00
parent 92f285cfc9
commit 2f59d8b05e

View file

@ -48,7 +48,7 @@ class VideoNode(Node):
error_msg = 'Syntax error. Expected: ``{% video URL ... %}``'
default_size = 'small'
re_size = re.compile('(?P<width>\d+[%]?)x(?P<height>\d+[%]?)')
re_size = re.compile('(?P<width>\d+%?)x(?P<height>\d+%?)')
def __init__(self, parser, token):
self.size = None