Mercurial > public > mercurial-scm > hg-stable
comparison mercurial/utils/urlutil.py @ 50928:dddd8e253c95
path-suboption: use str for "delta_reuse_policy" suboptions
That second argument refer to an attribute and do not needs to be bytes.
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Wed, 30 Aug 2023 00:47:48 +0200 |
parents | 9f3e4b60bfe6 |
children | 5f3c2adcc69c |
comparison
equal
deleted
inserted
replaced
50927:9f3e4b60bfe6 | 50928:dddd8e253c95 |
---|---|
756 DELTA_REUSE_POLICIES_NAME = dict(i[::-1] for i in DELTA_REUSE_POLICIES.items()) | 756 DELTA_REUSE_POLICIES_NAME = dict(i[::-1] for i in DELTA_REUSE_POLICIES.items()) |
757 | 757 |
758 | 758 |
759 @pathsuboption( | 759 @pathsuboption( |
760 b'pulled-delta-reuse-policy', | 760 b'pulled-delta-reuse-policy', |
761 b'delta_reuse_policy', | 761 'delta_reuse_policy', |
762 display=DELTA_REUSE_POLICIES_NAME.get, | 762 display=DELTA_REUSE_POLICIES_NAME.get, |
763 ) | 763 ) |
764 def delta_reuse_policy(ui, path, value): | 764 def delta_reuse_policy(ui, path, value): |
765 if value not in DELTA_REUSE_POLICIES: | 765 if value not in DELTA_REUSE_POLICIES: |
766 path_name = path.name | 766 path_name = path.name |