mirror of
				https://github.com/kevinveenbirkenbach/computer-playbook.git
				synced 2025-11-03 19:58:14 +00:00 
			
		
		
		
	Solved bug
This commit is contained in:
		@@ -15,13 +15,13 @@ def get_expected_statuses(domain: str, parts: list[str], redirected_domains: set
 | 
			
		||||
    Returns:
 | 
			
		||||
        A list of expected HTTP status codes.
 | 
			
		||||
    """
 | 
			
		||||
    {%- if domains | get_domain('listmonk') | safe_var | bool %}
 | 
			
		||||
    {%- if domains.listmonk | safe_var | bool %}
 | 
			
		||||
    if domain == '{{domains | get_domain('listmonk')}}':
 | 
			
		||||
        return [404]
 | 
			
		||||
    {%- endif %}
 | 
			
		||||
    if (parts and parts[0] == 'www') or (domain in redirected_domains):
 | 
			
		||||
        return [301]
 | 
			
		||||
    {%- if domains | get_domain('yourls') | safe_var | bool %}
 | 
			
		||||
    {%- if domains.yourls | safe_var | bool %}
 | 
			
		||||
    if domain == '{{domains | get_domain('yourls')}}':
 | 
			
		||||
        return [403]
 | 
			
		||||
    {%- endif %}
 | 
			
		||||
@@ -48,7 +48,7 @@ for filename in os.listdir(config_path):
 | 
			
		||||
        url = f"{{ web_protocol }}://{domain}"
 | 
			
		||||
        
 | 
			
		||||
        redirected_domains = [domain['source'] for domain in {{redirect_domain_mappings}}]
 | 
			
		||||
        {%- if domains | get_domain('mailu') | safe_var | bool %}
 | 
			
		||||
        {%- if domains.mailu | safe_var | bool %}
 | 
			
		||||
        redirected_domains.append("{{domains | get_domain('mailu')}}")
 | 
			
		||||
        {%- endif %}
 | 
			
		||||
 | 
			
		||||
 
 | 
			
		||||
		Reference in New Issue
	
	Block a user