diff --git a/Exporter.php b/Exporter.php index 40a3e9d..0754de4 100644 --- a/Exporter.php +++ b/Exporter.php @@ -66,9 +66,8 @@ private function setPosts($type = 'post') 'content' => wpautop($post->post_content), 'author' => $author, ), - 'categories' => array_map(function ($category) { - return $category->slug; - }, get_the_category($post->ID)), + 'categories' => wp_list_pluck(get_the_category($post->ID), 'slug'), + 'tags' => wp_list_pluck(get_the_tags($post->ID), 'slug'), ); foreach ($this->metadata('post', $post) as $key => $meta) { @@ -90,7 +89,7 @@ private function setPages() 'order' => $page->menu_order, 'data' => array( 'title' => $page->post_title, - 'post_content' => $page->post_content, + 'content' => $page->post_content, ), );