From a701db272d157f089f5da6d7ac19f28455dd6a3a Mon Sep 17 00:00:00 2001 From: Mark Jaquith Date: Mon, 7 Feb 2011 19:58:41 +0000 Subject: [PATCH] Skip authors that no longer exist when doing an export. props nacin. fixes #16479 git-svn-id: https://develop.svn.wordpress.org/trunk@17415 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-admin/includes/export.php | 2 ++ 1 file changed, 2 insertions(+) diff --git a/wp-admin/includes/export.php b/wp-admin/includes/export.php index baa133f299..2efd0405af 100644 --- a/wp-admin/includes/export.php +++ b/wp-admin/includes/export.php @@ -241,6 +241,8 @@ function export_wp( $args = array() ) { foreach ( (array) $results as $result ) $authors[] = get_userdata( $result->post_author ); + $authors = array_filter( $authors ); + foreach( $authors as $author ) { echo "\t"; echo '' . $author->ID . '';