[gnome-doc-utils] [xml2po] Don't use start parameter of enumerate (introduced in Python 2.6)
- From: Claude Paroz <claudep src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [gnome-doc-utils] [xml2po] Don't use start parameter of enumerate (introduced in Python 2.6)
- Date: Sun, 2 Aug 2009 14:06:07 +0000 (UTC)
commit ba9f86d68bdb2105f9dd2c2cff24a4830e809d5f
Author: Claude Paroz <claude 2xlibre net>
Date: Sun Aug 2 16:04:12 2009 +0200
[xml2po] Don't use start parameter of enumerate (introduced in Python 2.6)
xml2po/xml2po/__init__.py | 4 ++--
1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/xml2po/xml2po/__init__.py b/xml2po/xml2po/__init__.py
index 641bb06..a26e269 100644
--- a/xml2po/xml2po/__init__.py
+++ b/xml2po/xml2po/__init__.py
@@ -475,9 +475,9 @@ class XMLDocument(object):
node.setLang('C')
if restart or worth:
- for i, repl in enumerate(myrepl, 1):
+ for i, repl in enumerate(myrepl):
replacement = '<%s>%s</%s>' % (repl[0], repl[3], repl[2])
- translation = translation.replace('<placeholder-%d/>' % i, replacement)
+ translation = translation.replace('<placeholder-%d/>' % (i+1), replacement)
if worth:
if self.app.operation == 'merge':
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]