Merge branch '2.2.x'

This commit is contained in:
David Lord 2023-03-11 08:23:08 -08:00
commit 7ee9ceb71e
No known key found for this signature in database
GPG key ID: 7A1C87E3F5BC42A8
11 changed files with 31 additions and 29 deletions

View file

@ -9,6 +9,7 @@ from collections.abc import Iterator as _abc_Iterator
from datetime import timedelta
from itertools import chain
from types import TracebackType
from urllib.parse import quote as _url_quote
import click
from werkzeug.datastructures import Headers
@ -25,7 +26,6 @@ from werkzeug.routing import RequestRedirect
from werkzeug.routing import RoutingException
from werkzeug.routing import Rule
from werkzeug.serving import is_running_from_reloader
from werkzeug.urls import url_quote
from werkzeug.utils import cached_property
from werkzeug.utils import redirect as _wz_redirect
from werkzeug.wrappers import Response as BaseResponse
@ -1710,7 +1710,8 @@ class Flask(Scaffold):
return self.handle_url_build_error(error, endpoint, values)
if _anchor is not None:
rv = f"{rv}#{url_quote(_anchor)}"
_anchor = _url_quote(_anchor, safe="%!#$&'()*+,/:;=?@")
rv = f"{rv}#{_anchor}"
return rv