Development

Changeset 1321

You must first sign up to be able to contribute.

Changeset 1321

Show
Ignore:
Timestamp:
05/05/06 14:51:54 (2 years ago)
Author:
fabien
Message:

fixed double decoration in output escaping (patch from Mike Squire - closes #509)

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/lib/view/escaper/sfOutputEscaper.class.php

    r1197 r1321  
    9393    if (is_object($value)) 
    9494    { 
    95       if ($value instanceof Traversable) 
     95      if ($value instanceof sfOutputEscaper) 
     96      { 
     97        // avoid double decoration when passing values from action template to component/partial 
     98        $copy = clone $value; 
     99 
     100        $copy->escapingMethod = $escapingMethod; 
     101 
     102        return $copy; 
     103      } 
     104      elseif ($value instanceof Traversable) 
    96105      { 
    97106        return new sfOutputEscaperIteratorDecorator($escapingMethod, $value);