diff mercurial/wireproto.py @ 20922:588e24f3eea3

wireproto: use decorator for the stream command
author Pierre-Yves David <pierre-yves.david@fb.com>
date Fri, 28 Mar 2014 14:43:11 -0700
parents 70ed3174ce69
children d771641b7051
line wrap: on
line diff
--- 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'),
 })