소스 검색

Merge remote branch 'stfalcon/patch-2'

* stfalcon/patch-2:
  Small refact. Without this I get a php Notice and Warnig if try getFlash() after clearing the session:
Fabien Potencier 14 년 전
부모
커밋
b042366353
1개의 변경된 파일1개의 추가작업 그리고 1개의 파일을 삭제
  1. 1 1
      src/Symfony/Component/HttpFoundation/Session.php

+ 1 - 1
src/Symfony/Component/HttpFoundation/Session.php

@@ -232,7 +232,7 @@ class Session implements \Serializable
 
     public function getFlash($name, $default = null)
     {
-        return array_key_exists($name, $this->attributes['_flash']) ? $this->attributes['_flash'][$name] : $default;
+        return array_key_exists($name, $this->getFlashes()) ? $this->attributes['_flash'][$name] : $default;
     }
 
     public function setFlash($name, $value)