Iterating dictionaries
This commit is contained in:
@@ -425,7 +425,7 @@ def _get_modulestore_branch_setting():
|
||||
|
||||
# compare hostname against the regex expressions set of mappings which will tell us which branch to use
|
||||
if mappings:
|
||||
for key in mappings.iterkeys():
|
||||
for key in mappings:
|
||||
if re.match(key, hostname):
|
||||
return mappings[key]
|
||||
if branch is None:
|
||||
|
||||
@@ -1,6 +1,6 @@
|
||||
<%! from django.utils.translation import ugettext as _ %>
|
||||
<form action="${action}" method="post">
|
||||
% for pk, pv in params.iteritems():
|
||||
% for pk, pv in params.items():
|
||||
<input type="hidden" name="${pk}" value="${pv}" />
|
||||
% endfor
|
||||
|
||||
|
||||
Reference in New Issue
Block a user