MCPcopy
hub / github.com/fastapi/fastapi / record_middleware

Function record_middleware

tests/test_frontend.py:479–483  ·  view source on GitHub ↗
(request: Request, call_next)

Source from the content-addressed store, hash-verified

477
478 @app.middleware("http")
479 async def record_middleware(request: Request, call_next):
480 calls.append("middleware-before")
481 response = await call_next(request)
482 calls.append("middleware-after")
483 return response
484
485 app.frontend("/", directory=dist)
486

Callers

nothing calls this directly

Calls 1

call_nextFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…