Cast $routeName to string
authorChuck Hagenbuch <chuck@horde.org>
Mon, 9 Aug 2010 04:37:54 +0000 (00:37 -0400)
committerChuck Hagenbuch <chuck@horde.org>
Mon, 9 Aug 2010 04:37:54 +0000 (00:37 -0400)
framework/Routes/lib/Horde/Routes/Utils.php

index 7c19d17..f2f6050 100644 (file)
@@ -36,7 +36,6 @@ class Horde_Routes_Utils
      */
     public $redirect;
 
-
     /**
      * Constructor
      *
@@ -102,7 +101,7 @@ class Horde_Routes_Utils
             // urlFor('named_route')
             // urlFor('named_route', array('id' => 3, ...))
             // urlFor('static_path')
-            $routeName = $first;
+            $routeName = (string)$first;
             $kargs = $second;
         }
 
@@ -131,7 +130,6 @@ class Horde_Routes_Utils
         $url = '';
 
         if (isset($routeName)) {
-
             if (isset($kargs['format']) && isset($this->mapper->routeNames['formatted_' . $routeName])) {
                 $route = $this->mapper->routeNames['formatted_' . $routeName];
             } elseif (isset($this->mapper->routeNames[$routeName])) {