Browse Source

fixing some bugs.

Taylor Otwell 13 years ago
parent
commit
d3f9391981
4 changed files with 7 additions and 3 deletions
  1. 1 1
      application/filters.php
  2. 2 2
      laravel/blade.php
  3. 2 0
      laravel/laravel.php
  4. 2 0
      laravel/messages.php

+ 1 - 1
application/filters.php

@@ -50,7 +50,7 @@ return array(
 
 	'after' => function($response)
 	{
-		Input::flash();
+		// Do stuff after every request to your application.
 	},
 
 

+ 2 - 2
laravel/blade.php

@@ -73,7 +73,7 @@ class Blade {
 	 */
 	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<?php $2$3: ?>', $value);
 	}
@@ -153,7 +153,7 @@ class Blade {
 	 */
 	protected static function matcher($function)
 	{
-		return '/(\s*)@'.$function.'(\s*\(.*?\))/';
+		return '/(\s*)@'.$function.'(\s*\(.*\))/';
 	}
 
 }

+ 2 - 0
laravel/laravel.php

@@ -216,6 +216,8 @@ $response->content = $response->render();
  */
 if (Config::$items['session']['driver'] !== '')
 {
+	Input::flash();
+
 	IoC::core('session')->save($driver);
 }
 

+ 2 - 0
laravel/messages.php

@@ -138,6 +138,8 @@ class Messages {
 	 */
 	protected function format($messages, $format)
 	{
+		$messages = (array) $messages;
+
 		foreach ($messages as $key => &$message)
 		{
 			$message = str_replace(':message', $message, $format);