Skip to content
On this page

Hide Order Protection From Abandoned Cart Emails

To hide Order Protection from abandoned cart emails:

  1. Go to Settings > Notifications > Abandoned checkout.

  2. Click Edit code in the top right corner.

  3. Add the following conditional statement to the file right after the {% for line in subtotal_line_items %} statement:

    liquid
    {% if line.product.title %}
       {% assign line_title = line.product.title %}
    {% else %}
       {% assign line_title = line.title %}
    {% endif %}
    {% if line_title != 'Order Protection' %}
  4. Close the conditional statement by adding {% endif %} just before the closing {% endfor %} statement.

    Here's an exmaple of everything in context:

    liquid
    <table class="row">
    {% for line in subtotal_line_items %}
       {% if line.product.title %}
          {% assign line_title = line.product.title %}
       {% else %}
          {% assign line_title = line.title %}
       {% endif %}
       {% if line_title != 'Order Protection' %}
          <!-- existing code -->
       {% endif %}
    {% endfor %}
    </table>
  5. Click Save.