comparison mercurial/hgweb/request.py @ 34513:34fcb0f66837

request: use trivial iterator over dictionary keys Differential Revision: https://phab.mercurial-scm.org/D968
author Augie Fackler <augie@google.com>
date Thu, 05 Oct 2017 14:26:09 -0400
parents 482d6f6dba91
children 528b21b853aa
comparison
equal deleted inserted replaced
34512:482d6f6dba91 34513:34fcb0f66837
37 'static': [('cmd', ['static']), ('file', None)] 37 'static': [('cmd', ['static']), ('file', None)]
38 } 38 }
39 39
40 def normalize(form): 40 def normalize(form):
41 # first expand the shortcuts 41 # first expand the shortcuts
42 for k in shortcuts.iterkeys(): 42 for k in shortcuts:
43 if k in form: 43 if k in form:
44 for name, value in shortcuts[k]: 44 for name, value in shortcuts[k]:
45 if value is None: 45 if value is None:
46 value = form[k] 46 value = form[k]
47 form[name] = value 47 form[name] = value