From 99985601528c305713f362d21ec8ef1b17a629cd Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Fri, 2 May 2014 18:46:17 +0000 Subject: [PATCH] Twenty Fourteen: Avoid a PHP notice in Ephemera widget. props jartes. fixes #28055. Built from https://develop.svn.wordpress.org/trunk@28248 git-svn-id: http://core.svn.wordpress.org/trunk@28076 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-content/themes/twentyfourteen/inc/widgets.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/wp-content/themes/twentyfourteen/inc/widgets.php b/wp-content/themes/twentyfourteen/inc/widgets.php index 61c1160ae6..9bd1e79efd 100644 --- a/wp-content/themes/twentyfourteen/inc/widgets.php +++ b/wp-content/themes/twentyfourteen/inc/widgets.php @@ -47,7 +47,7 @@ class Twenty_Fourteen_Ephemera_Widget extends WP_Widget { * @param array $instance An array of settings for this widget instance. */ public function widget( $args, $instance ) { - $format = $instance['format']; + $format = isset( $instance['format'] ) && in_array( $instance['format'], $this->formats ) ? $instance['format'] : 'aside'; switch ( $format ) { case 'image':