Started to increase the phpstan level

This commit is contained in:
Jan Böhmer 2023-06-13 10:36:34 +02:00
parent 71cd4057a7
commit fc3290271c
29 changed files with 119 additions and 55 deletions

View file

@ -123,6 +123,6 @@ final class EntityExtension extends AbstractExtension
}
}
return false;
return null;
}
}

View file

@ -54,7 +54,7 @@ final class TwigCoreExtension extends AbstractExtension
*/
new TwigTest('instanceof', static fn($var, $instance) => $var instanceof $instance),
/* Checks if a given variable is an object. E.g. `x is object` */
new TwigTest('object', static fn($var): object => is_object($var)),
new TwigTest('object', static fn($var): bool => is_object($var)),
];
}