Commit 88aec84f authored by Denis Laxalde's avatar Denis Laxalde
Browse files

[hooks] Remove list() around repo.sources_by_uri

There's no need to convert it as a list anymore since sources_by_uri is a
property and will not be modified.

--HG--
branch : 3.25
parent f54286c1cef5
......@@ -56,7 +56,7 @@ class UpdateFeedsStartupHook(hook.Hook):
def update_feeds(repo):
# take a list to avoid iterating on a dictionary whose size may
# change
for uri, source in list(repo.sources_by_uri.items()):
for uri, source in repo.sources_by_uri.items():
if (uri == 'system'
or not repo.config.source_enabled(source)
or not source.config['synchronize']):
......
......@@ -1063,7 +1063,7 @@ class SynchronizeSourceCommand(Command):
else:
sources.append(source)
else:
for uri, source in list(repo.sources_by_uri.items()):
for uri, source in repo.sources_by_uri.items():
if (uri != 'system' and
repo.config.source_enabled(source) and
source.config['synchronize']):
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment