refactor messages class.

This commit is contained in:
Taylor Otwell 2011-08-06 20:47:20 -05:00
parent 8ddfdd9e7a
commit af4403bac5
1 changed files with 1 additions and 4 deletions

View File

@ -70,10 +70,7 @@ public function first($key, $format = ':message')
*/ */
public function get($key = null, $format = ':message') public function get($key = null, $format = ':message')
{ {
if (is_null($key)) if (is_null($key)) return $this->all($format);
{
return $this->all($format);
}
return (array_key_exists($key, $this->messages)) ? $this->format($this->messages[$key], $format) : array(); return (array_key_exists($key, $this->messages)) ? $this->format($this->messages[$key], $format) : array();
} }