From 644849ac0e4e497cd8eb88f8f1dfc144666c6a19 Mon Sep 17 00:00:00 2001 From: Matt Mullenweg Date: Mon, 26 Mar 2007 18:05:28 +0000 Subject: [PATCH] If we don't have IDs at this point, bail out. There are no tag defaults. Should fix #4035 though I can't recreate their particular error. git-svn-id: https://develop.svn.wordpress.org/trunk@5113 602fd350-edb4-49c9-b593-d223f7449a82 --- wp-includes/post.php | 3 +++ 1 file changed, 3 insertions(+) diff --git a/wp-includes/post.php b/wp-includes/post.php index 581c9391a8..14544ced68 100644 --- a/wp-includes/post.php +++ b/wp-includes/post.php @@ -789,6 +789,9 @@ function wp_set_post_tags( $post_id = 0, $tags = '' ) { $tag_ids[] = $tag_id; } + if ( !is_array( $tag_ids ) ) + return false; + $tag_ids = array_unique( $tag_ids ); // First the old tags