
    g]                     >    d dl mZ d dlmZ d dlmZ  G d de      Zy)    )settings)StaticFilesHandler)Commandc                   ,     e Zd ZdZ fdZ fdZ xZS )r   zMStarts a lightweight web server for development and also serves static files.c                 x    t         |   |       |j                  dddd       |j                  dddd	       y )
Nz
--nostaticstore_falseuse_static_handlerzCTells Django to NOT automatically serve static files at STATIC_URL.)actiondesthelpz
--insecure
store_trueinsecure_servingz3Allows serving static files even if DEBUG is False.)superadd_argumentsadd_argument)selfparser	__class__s     /var/www/python.vincentserveurtest.ovh/public_html/venv/lib/python3.12/site-packages/django/contrib/staticfiles/management/commands/runserver.pyr   zCommand.add_arguments   sP    f% %V	 	 	
 	#F	 	 	
    c                 x    t        |   |i |}|d   }|d   }|rt        j                  s|rt	        |      S |S )z
        Return the static files serving handler wrapping the default handler,
        if static files should be served. Otherwise return the default handler.
        r	   r   )r   get_handlerr   DEBUGr   )r   argsoptionshandlerr	   r   r   s         r   r   zCommand.get_handler   sM    
 '%t7w7$%9:"#568>>5E%g..r   )__name__
__module____qualname__r   r   r   __classcell__)r   s   @r   r   r      s    W 	

 
r   r   N)django.confr   #django.contrib.staticfiles.handlersr   )django.core.management.commands.runserverr   RunserverCommand r   r   <module>r&      s      B Q r   