comparison hgext/lfs/pointer.py @ 48917:1672c5af1271

lfs: remove pycompat.iteritems() Differential Revision: https://phab.mercurial-scm.org/D12322
author Gregory Szorc <gregory.szorc@gmail.com>
date Mon, 21 Feb 2022 11:06:46 -0700
parents f254fc73d956
children f4733654f144
comparison
equal deleted inserted replaced
48916:bac59722c5a3 48917:1672c5af1271
38 _(b'cannot parse git-lfs text: %s') % stringutil.pprint(text) 38 _(b'cannot parse git-lfs text: %s') % stringutil.pprint(text)
39 ) 39 )
40 40
41 def serialize(self): 41 def serialize(self):
42 sortkeyfunc = lambda x: (x[0] != b'version', x) 42 sortkeyfunc = lambda x: (x[0] != b'version', x)
43 items = sorted(pycompat.iteritems(self.validate()), key=sortkeyfunc) 43 items = sorted(self.validate().items(), key=sortkeyfunc)
44 return b''.join(b'%s %s\n' % (k, v) for k, v in items) 44 return b''.join(b'%s %s\n' % (k, v) for k, v in items)
45 45
46 def oid(self): 46 def oid(self):
47 return self[b'oid'].split(b':')[-1] 47 return self[b'oid'].split(b':')[-1]
48 48