Secure your code as it's written. Use Snyk Code to scan source code in minutes - no build needed - and fix issues immediately.
def createPoFile(self):
po = polib.POFile()
withMeta = self._context["jobconf"].get("translate/pofile-with-metadata", True)
if withMeta:
now = util.nowString()
po.metadata['Project-Id-Version'] = '1.0'
po.metadata['Report-Msgid-Bugs-To'] = 'you@your.org'
po.metadata['POT-Creation-Date'] = now
po.metadata['PO-Revision-Date'] = now
po.metadata['Last-Translator'] = 'you '
po.metadata['Language-Team'] = 'Team '
po.metadata['MIME-Version'] = '1.0'
po.metadata['Content-Type'] = 'text/plain; charset=utf-8'
po.metadata['Content-Transfer-Encoding'] = '8bit'
return po
def createPoFile(self):
po = polib.POFile()
withMeta = self._context["jobconf"].get("translate/pofile-with-metadata", True)
if withMeta:
now = util.nowString()
po.metadata['Project-Id-Version'] = '1.0'
po.metadata['Report-Msgid-Bugs-To'] = 'you@your.org'
po.metadata['POT-Creation-Date'] = now
po.metadata['PO-Revision-Date'] = now
po.metadata['Last-Translator'] = 'you '
po.metadata['Language-Team'] = 'Team '
po.metadata['MIME-Version'] = '1.0'
po.metadata['Content-Type'] = 'text/plain; charset=utf-8'
po.metadata['Content-Transfer-Encoding'] = '8bit'
return po