OwlCyberSecurity - MANAGER
Edit File: loader.cpython-39.pyc
a ���e � @ sD d dl mZ d dlmZ ddd�Zd dd�Zddd �Zdd d�ZdS )� )�engines)�TemplateDoesNotExistNc C sf g }t |�}|D ]D}z|�| �W S tyR } z|�|� W Y d}~qd}~0 0 qt| |d��dS )zt Load and return a template for the given name. Raise TemplateDoesNotExist if no such template exists. N��chain)�_engine_list�get_templater �append)� template_name�usingr r �engine�e� r �W/home/gouroczh/virtualenv/pat/3.9/lib/python3.9/site-packages/django/template/loader.pyr s "r c C s� t | t�rtd| ��g }t|�}| D ]R}|D ]H}z|�|�W S tyt } z|�|� W Y d}~q.d}~0 0 q.q&| r�td�| �|d��ntd��dS )z� Load and return a template for one of the given names. Try names in order and return the first template found. Raise TemplateDoesNotExist if no such template exists. z�select_template() takes an iterable of template names but got a string: %r. Use get_template() if you want to load a single template by name.Nz, r zNo template names provided)� isinstance�str� TypeErrorr r r r �join)Ztemplate_name_listr r r r r r r r r �select_template s"