Remove unnecessary repeated definitions of the cleanup macro
This commit is contained in:
@ -1489,6 +1489,7 @@ script:
|
||||
data:
|
||||
who: '{{ who }}'
|
||||
message: >-
|
||||
{% from 'formatting.jinja' import cleanup %}
|
||||
{% macro greeting() %}
|
||||
<p>
|
||||
{% if now().strftime('%H')|int < 12%}
|
||||
@ -1783,14 +1784,6 @@ script:
|
||||
] | random }}
|
||||
{% endmacro %}
|
||||
|
||||
|
||||
{# a macro that removes all newline characters, empty spaces, and returns formatted text. Also replaces all Underscores with Spaces #}
|
||||
{%- macro cleanup(data) -%}
|
||||
{%- for item in data.split("\n") if item | trim != "" -%}
|
||||
{{ item | trim | replace("_", " ") }} {% endfor -%}
|
||||
{%- endmacro -%}
|
||||
|
||||
|
||||
{# ********************************************* #}
|
||||
{# ******** Start the Speech routines ******** #}
|
||||
{# ********************************************* #}
|
||||
|
Reference in New Issue
Block a user