Browse files

some type fixes

  • Loading branch information...
1 parent 519d35c commit b80f634308663670251a012ac25302bb4598e98a @Tobion Tobion committed with arnaud-lb Nov 11, 2012
Showing with 11 additions and 10 deletions.
  1. +9 −9 CompiledRoute.php
  2. +1 −0 Matcher/Dumper/DumperCollection.php
  3. +1 −1 RouteCollection.php
View
18 CompiledRoute.php
@@ -30,18 +30,18 @@ class CompiledRoute
/**
* Constructor.
*
- * @param string $staticPrefix The static prefix of the compiled route
- * @param string $regex The regular expression to use to match this route
- * @param array $tokens An array of tokens to use to generate URL for this route
- * @param array $pathVariables An array of path variables
- * @param array $hostnameRegex|null Hostname regex
- * @param array $hostnameTokens Hostname tokens
- * @param array $hostnameVariables An array of hostname variables
- * @param array $variables An array of variables (variables defined in the path and in the hostname patterns)
+ * @param string $staticPrefix The static prefix of the compiled route
+ * @param string $regex The regular expression to use to match this route
+ * @param array $tokens An array of tokens to use to generate URL for this route
+ * @param array $pathVariables An array of path variables
+ * @param string|null $hostnameRegex Hostname regex
+ * @param array $hostnameTokens Hostname tokens
+ * @param array $hostnameVariables An array of hostname variables
+ * @param array $variables An array of variables (variables defined in the path and in the hostname patterns)
*/
public function __construct($staticPrefix, $regex, array $tokens, array $pathVariables, $hostnameRegex = null, array $hostnameTokens = array(), array $hostnameVariables = array(), array $variables = array())
{
- $this->staticPrefix = $staticPrefix;
+ $this->staticPrefix = (string) $staticPrefix;
$this->regex = $regex;
$this->tokens = $tokens;
$this->pathVariables = $pathVariables;
View
1 Matcher/Dumper/DumperCollection.php
@@ -20,6 +20,7 @@ class DumperCollection implements \IteratorAggregate
{
private $parent;
private $children = array();
+ private $attributes = array();
/**
* Returns the children routes and collections.
View
2 RouteCollection.php
@@ -282,7 +282,7 @@ public function getHostnamePattern()
*/
public function setHostnamePattern($pattern)
{
- $this->hostnamePattern = $pattern;
+ $this->hostnamePattern = (string) $pattern;
if ('' === $pattern) {
return;

0 comments on commit b80f634

Please sign in to comment.