changeset 20911:1bb8ed6c000c

wireproto: use decorator for the capabilities command
author Pierre-Yves David <pierre-yves.david@fb.com>
date Fri, 28 Mar 2014 14:37:28 -0700
parents acbfce12fafd
children 96ecb77f971d
files mercurial/wireproto.py
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/mercurial/wireproto.py	Fri Mar 28 14:37:02 2014 -0700
+++ b/mercurial/wireproto.py	Fri Mar 28 14:37:28 2014 -0700
@@ -571,6 +571,7 @@
 
 # If you are writting and extension and consider wrapping this function. Wrap
 # `_capabilities` instead.
+@wireprotocommand('capabilities')
 def capabilities(repo, proto):
     return ' '.join(_capabilities(repo, proto))
 
@@ -785,7 +786,6 @@
         os.unlink(tempname)
 
 commands.update({
-    'capabilities': (capabilities, ''),
     'changegroup': (changegroup, 'roots'),
     'changegroupsubset': (changegroupsubset, 'bases heads'),
     'debugwireargs': (debugwireargs, 'one two *'),