splitwords: prevent to split to empty values by multiple separator characters together

pull/1446/head^2^2
sebres 2016-05-23 15:33:45 +02:00
parent 01d0506ea0
commit 156065e70d
1 changed files with 1 additions and 1 deletions

View File

@ -136,4 +136,4 @@ def splitwords(s):
"""
if not s:
return []
return filter(bool, map(str.strip, re.split('[ ,\n]', s)))
return filter(bool, map(str.strip, re.split('[ ,\n]+', s)))