Can I use multiple if statement in with with same validation? Multiple if statement with similar validation will crash(WSOD) my website and I'm not sure if this an expected behavior, meaning what I'm doing is wrong. Or this is a bug, which I should fill into Drupal.org as bug.

Here is my code.

  {%  if page.footer_second and page.footer_third %}
       {% set col_class = 'six' %}

   {# If we have 3 columns#}
   {%  if page.footer_first and page.footer_second and page.footer_third %}
       {% set col_class = 'four' %}

   {# If we have 2 columns#}
   {%  elseif page.footer_first or page.footer_first or footer_third %}
        {% set col_class = 'eight' %}
   {% else %}
        {% set col_class = 'ten' %}
   {% endif %}


   &lt;div class="{{ col_class }} columns"&gt;   
     {{ page.footer_first }}
   &lt;/div&gt;

    &lt;div class="{{ col_class }} columns"&gt;
     {{ page.footer_second }}
     &lt;/div&gt;
     &lt;div class="{{ col_class }} columns"&gt;
         {{ page.footer_third }}
      &lt;/div&gt;
    {% endif %}


If I remove one of my if statement my website will not crash (WSOD).

What I'm doing wrong ?
What's jumping out at me is this line:

elseif page.footer_first or page.footer_first or footer_third


It's checking page.footer_first twice, and footer_third, which based on the code you've shown is not a valid variable, it should be page.footer_third. I'm guessing this should be more like:

elseif page.footer_first or page.footer_second or page.footer_third