mirror of
https://github.com/twigphp/Twig.git
synced 2026-09-16 20:36:33 +00:00
minor #3441 Remove is_int since typehint exists (ybenhssaien)
This PR was merged into the 3.x branch.
Discussion
----------
Remove is_int since typehint exists
Since `$optimizers` param is always `int` no needs to check `is_int`
Commits
-------
d8a4113a Remove is_int since typehint exists
This commit is contained in:
@@ -51,7 +51,7 @@ final class OptimizerNodeVisitor implements NodeVisitorInterface
|
||||
*/
|
||||
public function __construct(int $optimizers = -1)
|
||||
{
|
||||
if (!\is_int($optimizers) || $optimizers > (self::OPTIMIZE_FOR | self::OPTIMIZE_RAW_FILTER)) {
|
||||
if ($optimizers > (self::OPTIMIZE_FOR | self::OPTIMIZE_RAW_FILTER)) {
|
||||
throw new \InvalidArgumentException(sprintf('Optimizer mode "%s" is not valid.', $optimizers));
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user