fix return walker
This commit is contained in:
parent
a6b43b93ac
commit
6fe40b055f
1 changed files with 3 additions and 3 deletions
|
@ -633,10 +633,10 @@ class TreeWalkerChain implements TreeWalker
|
|||
private function getWalker($walkerClass)
|
||||
{
|
||||
$key = array_search($walkerClass, $this->_walkersClasses);
|
||||
if (isset($this->_walkers[$key])) {
|
||||
return $this->_walkers[$key];
|
||||
if (!isset($this->_walkers[$key])) {
|
||||
$this->_walkers[$key] = new $walkerClass($this->_query, $this->_parserResult, $this->_queryComponents);
|
||||
}
|
||||
|
||||
return new $walkerClass($this->_query, $this->_parserResult, $this->_queryComponents);
|
||||
return $this->_walkers[$key];
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue