How can I create a flow with customer tags and product tags?

hi im trying to make a flow similar to :

{% if customer.tags contains ‘dealer’ and product.tags does not contains ‘customerstage’%}
{% render ‘product-accordions’ %}
{% endif%}

or something like

{% if customer.tags contains ‘dealer’ %}
{% render ‘product-accordions’ %}
{% elsif product.tags contains ‘customerstage’%}
do nothing
{% endif%}

i’ve tried to replace my do nothing in the second flow with a text flow but the product-accordions is always showing

any help will be appreciate thank you !

I don’t think does not contain is valid liquid. Also, your second example is not the same logic as the first and it would always output if dealer is in the tags.

I think you want unless instead of does not contain, but you need to nest that condition instead the if statement.

According to https://shopify.github.io/liquid/tags/control-flow/ you can use ‘unless’ instead of an if-then statement.