Author: jphilip
Date: 2010-04-19 21:50:43 +0200 (Mon, 19 Apr 2010)
New Revision: 29215

Modified:
   
plugins/sfDoctrineTreePlugin/modules/sfDoctrineTree/templates/_nested_set_list.php
Log:
Change to avoid PHP warnings

Modified: 
plugins/sfDoctrineTreePlugin/modules/sfDoctrineTree/templates/_nested_set_list.php
===================================================================
--- 
plugins/sfDoctrineTreePlugin/modules/sfDoctrineTree/templates/_nested_set_list.php
  2010-04-19 18:58:36 UTC (rev 29214)
+++ 
plugins/sfDoctrineTreePlugin/modules/sfDoctrineTree/templates/_nested_set_list.php
  2010-04-19 19:50:43 UTC (rev 29215)
@@ -13,13 +13,13 @@
   $noRootAttr =  " noDrag='true' noSiblings='true' noDelete='true'";
   if ($no_root_rename) $noRootAttr .= " noRename='true'";
   if (isset($options['noAdd']) && $options['noAdd']) $noRootAttr .= " 
noAdd='true'";
-  if (get_class($options) == 'sfOutputEscaperArrayDecorator')
+  if (is_object($options) && get_class($options) == 
'sfOutputEscaperArrayDecorator')
     $options = $options->getRawValue();
     $nodeNoAttr = _tag_options($options); ?>
   <?php foreach($records AS $record):
   $noAttr = $record->getNode()->getLevel() == 0 ?  $noRootAttr : $nodeNoAttr;
   $identifier = $record->identifier();
-  if (get_class($identifier) == 'sfOutputEscaperArrayDecorator')
+  if (is_object($identifier) && get_class($identifier) == 
'sfOutputEscaperArrayDecorator')
     $identifier = $identifier->getRawValue();
   $identifier = array_values($identifier); ?>
   <?php if($prevLevel > 0 && $record->getNode()->getLevel() == $prevLevel)  
echo '</li>'; ?>  

-- 
You received this message because you are subscribed to the Google Groups 
"symfony SVN" group.
To post to this group, send email to [email protected].
To unsubscribe from this group, send email to 
[email protected].
For more options, visit this group at 
http://groups.google.com/group/symfony-svn?hl=en.

Reply via email to