From 0d05031835c269ff76600ffe30cd24340ecffcf0 Mon Sep 17 00:00:00 2001 From: Dries Buytaert Date: Sun, 10 Apr 2011 23:38:58 +0200 Subject: [PATCH] - Patch #998612 by longwave: drupal_render() doesn't render 0 when set into #markup property. --- includes/common.inc | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/includes/common.inc b/includes/common.inc index 5f56d4413d0..814ca549a6f 100644 --- a/includes/common.inc +++ b/includes/common.inc @@ -5568,9 +5568,9 @@ function drupal_render(&$elements) { return $cached_output; } - // If #markup is not empty, set #type. This allows to specify just #markup on - // an element without setting #type. - if (!empty($elements['#markup']) && !isset($elements['#type'])) { + // If #markup is set, ensure #type is set. This allows to specify just #markup + // on an element without setting #type. + if (isset($elements['#markup']) && !isset($elements['#type'])) { $elements['#type'] = 'markup'; }