copies: simplify chain loop
This is a mostly gratuitous change to make the code more direct.
Differential Revision: https://phab.mercurial-scm.org/D7131
--- a/mercurial/copies.py Thu Oct 17 02:17:24 2019 +0200
+++ b/mercurial/copies.py Thu Oct 17 16:06:06 2019 +0200
@@ -67,10 +67,7 @@
"""chain two sets of copies 'a' and 'b'"""
t = a.copy()
for k, v in pycompat.iteritems(b):
- if v in t:
- t[k] = t[v]
- else:
- t[k] = v
+ t[k] = t.get(v, v)
return t