Sync oslo gettextutils

Change-Id: Id347e157ca2ccefe510b3328ea0047c87f25b3e4
This commit is contained in:
Luis A. Garcia 2013-08-06 19:30:38 +00:00
parent f27fba3ad7
commit e0de5bf99e

View File

@ -137,7 +137,7 @@ class Message(UserString.UserString, object):
# look for %(blah) fields in string;
# ignore %% and deal with the
# case where % is first character on the line
keys = re.findall('(?:[^%]|^)%\((\w*)\)[a-z]', full_msg)
keys = re.findall('(?:[^%]|^)?%\((\w*)\)[a-z]', full_msg)
# if we don't find any %(blah) blocks but have a %s
if not keys and re.findall('(?:[^%]|^)%[a-z]', full_msg):