# HG changeset patch # User Pierre-Yves David # Date 2014-03-28 21:38:19 # Node ID 96ecb77f971d5d5728b11ba66a03376cf814d911 # Parent 1bb8ed6c000cc5f07cbded303eb9bfef84b72af9 wireproto: use decorator for the changegroup command diff --git a/mercurial/wireproto.py b/mercurial/wireproto.py --- a/mercurial/wireproto.py +++ b/mercurial/wireproto.py @@ -575,6 +575,7 @@ def _capabilities(repo, proto): def capabilities(repo, proto): return ' '.join(_capabilities(repo, proto)) +@wireprotocommand('changegroup', 'roots') def changegroup(repo, proto, roots): nodes = decodelist(roots) cg = repo.changegroup(nodes, 'serve') @@ -786,7 +787,6 @@ def unbundle(repo, proto, heads): os.unlink(tempname) commands.update({ - 'changegroup': (changegroup, 'roots'), 'changegroupsubset': (changegroupsubset, 'bases heads'), 'debugwireargs': (debugwireargs, 'one two *'), 'getbundle': (getbundle, '*'),