Просмотр исходного кода

[OutputEscaper] switched to casting object as string rather than call magic method directly

Kris Wallsmith 15 лет назад
Родитель
Сommit
8c0f7e8569
1 измененных файлов с 1 добавлено и 1 удалено
  1. 1 1
      src/Symfony/Components/OutputEscaper/ObjectDecorator.php

+ 1 - 1
src/Symfony/Components/OutputEscaper/ObjectDecorator.php

@@ -92,6 +92,6 @@ class ObjectDecorator extends GetterDecorator
      */
     public function __toString()
     {
-        return $this->escape($this->escaper, $this->value->__toString());
+        return $this->escape($this->escaper, (string) $this->value);
     }
 }