wireproto: use decorator for the stream command
authorPierre-Yves David <pierre-yves.david@fb.com>
Fri, 28 Mar 2014 14:43:11 -0700
changeset 20922 588e24f3eea3
parent 20921 70ed3174ce69
child 20923 d771641b7051
wireproto: use decorator for the stream command
mercurial/wireproto.py
--- a/mercurial/wireproto.py	Fri Mar 28 14:42:55 2014 -0700
+++ b/mercurial/wireproto.py	Fri Mar 28 14:43:11 2014 -0700
@@ -683,6 +683,7 @@
     # this is it's own function so extensions can override it
     return repo.store.walk()
 
+@wireprotocommand('stream_out')
 def stream(repo, proto):
     '''If the server supports streaming clone, it advertises the "stream"
     capability with a value representing the version and flags of the repo
@@ -796,6 +797,5 @@
         os.unlink(tempname)
 
 commands.update({
-    'stream_out': (stream, ''),
     'unbundle': (unbundle, 'heads'),
 })