From d3f9391981ea56aa716f77fecff801a150c295e3 Mon Sep 17 00:00:00 2001 From: Taylor Otwell Date: Tue, 15 Nov 2011 23:15:58 -0600 Subject: [PATCH] fixing some bugs. --- application/filters.php | 2 +- laravel/blade.php | 4 ++-- laravel/laravel.php | 2 ++ laravel/messages.php | 2 ++ 4 files changed, 7 insertions(+), 3 deletions(-) diff --git a/application/filters.php b/application/filters.php index dd4917a3..41ac6010 100644 --- a/application/filters.php +++ b/application/filters.php @@ -50,7 +50,7 @@ 'after' => function($response) { - Input::flash(); + // Do stuff after every request to your application. }, diff --git a/laravel/blade.php b/laravel/blade.php index 7baeee22..36b36144 100644 --- a/laravel/blade.php +++ b/laravel/blade.php @@ -73,7 +73,7 @@ protected static function compile_echos($value) */ protected static function compile_structure_openings($value) { - $pattern = '/(\s*)@(if|elseif|foreach|for|while)(\s*\(.*?\))/'; + $pattern = '/(\s*)@(if|elseif|foreach|for|while)(\s*\(.*\))/'; return preg_replace($pattern, '$1', $value); } @@ -153,7 +153,7 @@ protected static function compile_section_end($value) */ protected static function matcher($function) { - return '/(\s*)@'.$function.'(\s*\(.*?\))/'; + return '/(\s*)@'.$function.'(\s*\(.*\))/'; } } \ No newline at end of file diff --git a/laravel/laravel.php b/laravel/laravel.php index 3545e83f..43933505 100644 --- a/laravel/laravel.php +++ b/laravel/laravel.php @@ -216,6 +216,8 @@ */ if (Config::$items['session']['driver'] !== '') { + Input::flash(); + IoC::core('session')->save($driver); } diff --git a/laravel/messages.php b/laravel/messages.php index 170915e6..32ed8fd8 100644 --- a/laravel/messages.php +++ b/laravel/messages.php @@ -138,6 +138,8 @@ public function all($format = ':message') */ protected function format($messages, $format) { + $messages = (array) $messages; + foreach ($messages as $key => &$message) { $message = str_replace(':message', $message, $format);