From: Derick Rethans Date: Thu, 7 Jul 2011 13:05:38 +0000 (+0100) Subject: Check the property regardless of whether tmp_item is valid/set. X-Git-Url: http://git.silmor.de/gitweb/?a=commitdiff_plain;h=f7ae76ef4b51ee482b512be9832fa0770bd62d8a;p=web%2Fkonrad%2Ftwig.git Check the property regardless of whether tmp_item is valid/set. --- diff --git a/twig.c b/twig.c index 8b7b84b..c18b4a6 100644 --- a/twig.c +++ b/twig.c @@ -660,10 +660,7 @@ PHP_FUNCTION(twig_template_get_attributes) tmp_properties = TWIG_GET_ARRAY_ELEMENT(tmp_class, "properties", strlen("properties")); tmp_item = TWIG_GET_ARRAY_ELEMENT_ZVAL(tmp_properties, item); - if (tmp_item) { - convert_to_string(tmp_item); - tmp_object_item = TWIG_PROPERTY(object, Z_STRVAL_P(tmp_item)); - } + tmp_object_item = TWIG_PROPERTY(object, item); if (tmp_item || tmp_object_item || TWIG_ARRAY_KEY_EXISTS(object, item) // FIXME: Array key? is that array access here? ) {