Skip to content

Commit

Permalink
Fix compatibility with PHP 7.4 (#199)
Browse files Browse the repository at this point in the history
  • Loading branch information
Rixafy authored and dg committed Sep 24, 2019
1 parent c690255 commit 25f857e
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/Latte/Runtime/FilterExecutor.php
Original file line number Diff line number Diff line change
Expand Up @@ -178,7 +178,8 @@ private function prepareFilter(string $name): array
? new \ReflectionMethod($callback[0], $callback[1])
: new \ReflectionFunction($callback);
$this->_static[$name][1] = ($tmp = $ref->getParameters())
&& (string) $tmp[0]->getType() === FilterInfo::class;
&& $tmp[0]->getType() !== null
&& $tmp[0]->getType()->getName() === FilterInfo::class;
}
return $this->_static[$name];
}
Expand Down

0 comments on commit 25f857e

Please sign in to comment.