]> git.ipfire.org Git - thirdparty/fastapi/fastapi.git/commitdiff
:bug: fix name of shutdown_event in docs (#105)
authorStratos Gerakakis <stratosgear@gmail.com>
Fri, 29 Mar 2019 14:39:57 +0000 (15:39 +0100)
committerSebastián Ramírez <tiangolo@gmail.com>
Fri, 29 Mar 2019 14:39:57 +0000 (18:39 +0400)
Fix name copy/paste name error in docs source for startup/shutdown events.

docs/src/events/tutorial002.py

index e28d5f5ba50938104c2aec0679712ba1c09ef146..a71fea8025307aec29246d5438c1b54a9048ce20 100644 (file)
@@ -4,7 +4,7 @@ app = FastAPI()
 
 
 @app.on_event("shutdown")
-def startup_event():
+def shutdown_event():
     with open("log.txt", mode="a") as log:
         log.write("Application shutdown")