]> git.ipfire.org Git - thirdparty/fastapi/fastapi.git/commitdiff
🐛 Fix `flask.escape` warning for internal tests (#9468)
authorSamuel Colvin <s@muelcolvin.com>
Tue, 9 May 2023 14:32:00 +0000 (15:32 +0100)
committerGitHub <noreply@github.com>
Tue, 9 May 2023 14:32:00 +0000 (14:32 +0000)
* fix flask.escape warning

* 📝 Fix highlight in docs for WSGI

---------

Co-authored-by: Sebastián Ramírez <tiangolo@gmail.com>
docs/en/docs/advanced/wsgi.md
docs_src/wsgi/tutorial001.py

index df8865961721d9f8de3b2111dcc3df5545f4136a..cfe3c78c11ca4be32e7ce8c45e8d4b8a9b31868b 100644 (file)
@@ -12,7 +12,7 @@ Then wrap the WSGI (e.g. Flask) app with the middleware.
 
 And then mount that under a path.
 
-```Python hl_lines="2-3  22"
+```Python hl_lines="2-3  23"
 {!../../../docs_src/wsgi/tutorial001.py!}
 ```
 
index 500ecf883eaf6a86d01e2936c6ceafa10187bb81..7f27a85a19ae7d3f82df2fa80fe58a7aba6714ce 100644 (file)
@@ -1,6 +1,7 @@
 from fastapi import FastAPI
 from fastapi.middleware.wsgi import WSGIMiddleware
-from flask import Flask, escape, request
+from flask import Flask, request
+from markupsafe import escape
 
 flask_app = Flask(__name__)