diff --git a/examples/vhosts.py b/examples/vhosts.py index 50c9b6f6..91b2b647 100644 --- a/examples/vhosts.py +++ b/examples/vhosts.py @@ -17,10 +17,6 @@ bp = Blueprint("bp", host="bp.example.com") async def hello(request): return response.text("Some defaults") -@app.route('/', host="example.com") -async def hello(request): - return response.text("Answer") - @app.route('/', host="sub.example.com") async def hello(request): return response.text("42") @@ -33,7 +29,7 @@ async def hello(request): async def hello(request): return response.text("42") -app.register_blueprint(bp) +app.blueprint(bp) if __name__ == '__main__': app.run(host="0.0.0.0", port=8000) \ No newline at end of file