mirror of
https://github.com/10h30/wordpress-export-to-markdown.git
synced 2026-07-11 18:56:14 +09:00
Filter out trashed and draft posts
This commit is contained in:
@@ -37,6 +37,7 @@ function collectPosts(data, config) {
|
||||
const turndownService = translator.initTurndownService();
|
||||
|
||||
const posts = getItemsOfType(data, 'post')
|
||||
.filter(post => post.status[0] !== 'trash' && post.status[0] !== 'draft')
|
||||
.map(post => ({
|
||||
// meta data isn't written to file, but is used to help with other things
|
||||
meta: {
|
||||
|
||||
Reference in New Issue
Block a user