Merge similar error strings for invalid data.

props pavelevap.
fixes #32329.

git-svn-id: https://develop.svn.wordpress.org/trunk@32477 602fd350-edb4-49c9-b593-d223f7449a82
This commit is contained in:
Dominik Schilling (ocean90)
2015-05-09 21:08:57 +00:00
parent bcbae1cee3
commit cfa32bc1d7
3 changed files with 7 additions and 7 deletions
+1 -1
View File
@@ -65,7 +65,7 @@ function set_post_format( $post, $format ) {
$post = get_post( $post );
if ( empty( $post ) )
return new WP_Error( 'invalid_post', __( 'Invalid post' ) );
return new WP_Error( 'invalid_post', __( 'Invalid post.' ) );
if ( ! empty( $format ) ) {
$format = sanitize_key( $format );