Commit 5f31c1d1 authored by David Edmundson's avatar David Edmundson
Browse files

Fix i18n pot to json extraction

parent 6dc66e09
......@@ -31,13 +31,15 @@ with open(potFileName, 'r') as infile:
currentId = ""
currentMsg = ""
continue
#split at first space
parts = line.split(' ', 1)
if len(parts) != 2:
continue
if parts[0] == "#:":
if line.startswith("#:"):
parts = line.split(' ', 1)
if len(parts) != 2:
continue
currentId = parts[1].split(":")[0]
elif parts[0] == "msgstr":
elif line.startswith("msgstr"):
parts = line.split(' ', 1)
if len(parts) != 2:
continue
msg = parts[1].strip('\"')
msg = msg.replace('\\\"', '\"')
currentMsg = msg
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment