Mercurial > ~astiob > upreckon > hgweb
diff config.py @ 73:b071ef77377c
String keys in pointmap are no longer treated as iterables except in legacy mode
author | Oleg Oshmyan <chortos@inbox.lv> |
---|---|
date | Thu, 06 Jan 2011 19:58:45 +0200 |
parents | b9d5857f7b9a |
children | aea4fc87698a |
line wrap: on
line diff
--- a/config.py Thu Jan 06 17:51:59 2011 +0200 +++ b/config.py Thu Jan 06 19:58:45 2011 +0200 @@ -140,11 +140,14 @@ module.path = problem_name newpointmap = {} for key in module.pointmap: - try: - for k in key: - newpointmap[k] = module.pointmap[key] - except TypeError: + if not options.legacy and isinstance(key, basestring): newpointmap[key] = module.pointmap[key] + else: + try: + for k in key: + newpointmap[k] = module.pointmap[key] + except TypeError: + newpointmap[key] = module.pointmap[key] module.pointmap = newpointmap if options.no_maxtime: module.maxtime = 0