diff options
Diffstat (limited to 'proxy/utils.py')
| -rw-r--r-- | proxy/utils.py | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/proxy/utils.py b/proxy/utils.py index 2b80f43..3fff388 100644 --- a/proxy/utils.py +++ b/proxy/utils.py | |||
| @@ -3,5 +3,9 @@ from starlette.requests import HTTPConnection | |||
| 3 | 3 | ||
| 4 | def get_path_with_query_string(connection: HTTPConnection) -> str: | 4 | def get_path_with_query_string(connection: HTTPConnection) -> str: |
| 5 | path = connection.url.path | 5 | path = connection.url.path |
| 6 | query_string = '?' + connection.scope['query_string'].decode() if connection.scope['query_string'] else '' | 6 | query_string = ( |
| 7 | "?" + connection.scope["query_string"].decode() | ||
| 8 | if connection.scope["query_string"] | ||
| 9 | else "" | ||
| 10 | ) | ||
| 7 | return f"{path}{query_string}" | 11 | return f"{path}{query_string}" |
