Fix streaming.md
This commit is contained in:
parent
0b53c413a7
commit
15ad07f03d
|
@ -44,7 +44,7 @@ from sanic.blueprints import Blueprint
|
|||
from sanic.response import stream, text
|
||||
|
||||
bp = Blueprint('blueprint_request_stream')
|
||||
app = Sanic('request_stream', is_request_stream=True)
|
||||
app = Sanic('request_stream')
|
||||
|
||||
|
||||
class SimpleView(HTTPMethodView):
|
||||
|
@ -72,11 +72,6 @@ async def handler(request):
|
|||
return stream(streaming)
|
||||
|
||||
|
||||
@app.get('/get')
|
||||
async def get(request):
|
||||
return text('OK')
|
||||
|
||||
|
||||
@bp.stream('/bp_stream')
|
||||
async def bp_handler(request):
|
||||
result = ''
|
||||
|
|
|
@ -34,11 +34,6 @@ async def handler(request):
|
|||
return stream(streaming)
|
||||
|
||||
|
||||
@app.get('/get')
|
||||
async def get(request):
|
||||
return text('OK')
|
||||
|
||||
|
||||
@bp.stream('/bp_stream')
|
||||
async def bp_handler(request):
|
||||
result = ''
|
||||
|
|
Loading…
Reference in New Issue
Block a user