From 232f1b7f6686148e4f77d244120d8f4c48d9181d Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Joakim=20Helle=C5=9Ben?= Date: Mon, 23 Mar 2026 23:32:32 +0100 Subject: [PATCH] Refactor wsgi.py to improve type hinting and remove unnecessary docstring --- config/wsgi.py | 14 +++++--------- 1 file changed, 5 insertions(+), 9 deletions(-) diff --git a/config/wsgi.py b/config/wsgi.py index cd6eab5..9634b0a 100644 --- a/config/wsgi.py +++ b/config/wsgi.py @@ -1,15 +1,11 @@ -"""WSGI config for config project. - -It exposes the WSGI callable as a module-level variable named ``application``. - -For more information on this file, see -https://docs.djangoproject.com/en/6.0/howto/deployment/wsgi/ -""" - import os +from typing import TYPE_CHECKING from django.core.wsgi import get_wsgi_application +if TYPE_CHECKING: + from django.core.handlers.wsgi import WSGIHandler + os.environ.setdefault("DJANGO_SETTINGS_MODULE", "config.settings") -application = get_wsgi_application() +application: WSGIHandler = get_wsgi_application()