Quantcast
Channel: configuration - Forum - FlexGet
Viewing all articles
Browse latest Browse all 716

"Jinja if" not processed in notify message

$
0
0

@Mirgolth wrote:

Hi,

From version 2.9.0 on, I migrated from notify_entries to notify. The Jinja2 elements from the message don't seem to be processed. The title seems be be correctly processed.

As both If statement ans notify were modified, I wonder if it's a problem with my conf (It used to work on 2.8.x ) or with the code.

Config:

  pushbullet:
    notify:
      entries:
        title: >
          {% if series_name is defined %}{{tvdb_series_name|d(series_name)}} - {{series_id}}
          {% elif imdb_name is defined %}{{imdb_name}} ({{imdb_year}})
          {% else %}{{title}}
          {% endif %}
        message: >
          {% if series_name is defined %}{{tvdb_series_name|d(series_name)}} - {{series_id}} - {{tvdb_ep_name|d('')}}{% if quality is defined %} ({{quality}}{% endif %}{% if proper is proper %} PROPER{% endif %})
          {% elif imdb_name is defined %}{{imdb_name}} ({{imdb_year}}){% if quality is defined %} ({{quality}}{% endif %}{% if proper is defined %} PROPER{% endif %})
          {% else %}{{title}}{% if quality is defined %} ({{quality}}{% endif %}{% if proper is defined %} PROPER{% endif %})
          {% endif %}
        via:
          - pushbullet:
              api_key: '{? pushbullet.key ?}'

Exemple output:

Shadowhunters - S02E02
{% if series_name is defined %}{{tvdb_series_name|d(series_name)}} - {{series_id}} - {{tvdb_ep_name|d('')}}{% if quality is defined %} ({{quality}}{% endif %}{% if proper is proper %} PROPER{% endif %}) {% elif imdb_name is defined %}{{imdb_name}} ({{imdb_year}}){% if quality is defined %} ({{quality}}{% endif %}{% if proper is defined %} PROPER{% endif %}) {% else %}{{title}}{% if quality is defined %} ({{quality}}{% endif %}{% if proper is defined %} PROPER{% endif %}) {% endif %}

Posts: 4

Participants: 2

Read full topic


Viewing all articles
Browse latest Browse all 716

Trending Articles