Explorar el Código

Ensure slash element is omitted when comment count is a boolean false - fixes ZF-10054

git-svn-id: http://framework.zend.com/svn/framework/standard/trunk@23077 44c647ce-9c0f-0410-b52a-842ac1e357ba
padraic hace 15 años
padre
commit
4fa3f123ba
Se han modificado 1 ficheros con 1 adiciones y 1 borrados
  1. 1 1
      library/Zend/Feed/Writer/Extension/Slash/Renderer/Entry.php

+ 1 - 1
library/Zend/Feed/Writer/Extension/Slash/Renderer/Entry.php

@@ -81,7 +81,7 @@ class Zend_Feed_Writer_Extension_Slash_Renderer_Entry
     {
         $count = $this->getDataContainer()->getCommentCount();
         if (!$count) {
-            $count = 0;
+            return;
         }
         $tcount = $this->_dom->createElement('slash:comments');
         $tcount->nodeValue = $count;