From f9cc2bec0d12f2e626a31cd8d5f0f8c13f347613 Mon Sep 17 00:00:00 2001 From: Kevin Ansfield Date: Thu, 13 Jun 2024 16:12:29 +0100 Subject: [PATCH] Fixed data generator not setting `posts.plaintext` value no issue - without `plaintext` set the API will not add generated excerpts to responses --- ghost/data-generator/lib/importers/PostsImporter.js | 1 + 1 file changed, 1 insertion(+) diff --git a/ghost/data-generator/lib/importers/PostsImporter.js b/ghost/data-generator/lib/importers/PostsImporter.js index 8e28a7fc62..81d9453740 100644 --- a/ghost/data-generator/lib/importers/PostsImporter.js +++ b/ghost/data-generator/lib/importers/PostsImporter.js @@ -81,6 +81,7 @@ class PostsImporter extends TableImporter { ]) }), html: content.map(paragraph => `

${paragraph}

`).join(''), + plaintext: content.join('\n\n'), email_recipient_filter: 'all', newsletter_id: this.type === 'post' && status === 'published' && luck(90) ? (visibility === 'paid' ? this.newsletters[0].id : this.newsletters[1].id) : null };