From f4dfecb62fd2d6bac9edecdd6be505d21644f3ad Mon Sep 17 00:00:00 2001 From: Manuel Ebert Date: Fri, 19 Aug 2016 21:44:12 +0000 Subject: [PATCH] Fix JSON export --- jrnl/templates/json.template | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/jrnl/templates/json.template b/jrnl/templates/json.template index 2666ef97..863047d4 100644 --- a/jrnl/templates/json.template +++ b/jrnl/templates/json.template @@ -20,14 +20,13 @@ extension: json {% block entry %} { "title": "{{ entry.title }}", - "body": "{{ entry.body }}", + "body": "{{ entry.body.replace("\n", "\\n") }}", "date": "{{ entry.date.strftime('%Y-%m-%d') }}", "time": "{{ entry.date.strftime('%H:%M') }}", {% if entry.uuid %} "uuid": "{{ entry.uuid }}", {% endif %} "starred": {{ "true" if entry.starred else "false" }} - } } {% endblock %}