From 4148dfda2567f3514fa53fb7ca787878c6de2368 Mon Sep 17 00:00:00 2001 From: Encre Informatique Date: Sat, 11 Dec 2021 09:58:33 -0300 Subject: [PATCH] fixed : add doc blocks to silence Symfony deprecations (#1922) * fixed : add doc blocks to silence Symfony deprecations Symfony 5.4 returning deprecations about ``` User Deprecated: Method "Twig\Extension\ExtensionInterface::getFunctions()" might add "array" as a native return type declaration in the future. Do the same in implementation "Nelmio\ApiDocBundle\Render\Html\GetNelmioAsset" now to avoid errors or add an explicit @return annotation to suppress this message. ``` * fixed : native hint --- Render/Html/GetNelmioAsset.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Render/Html/GetNelmioAsset.php b/Render/Html/GetNelmioAsset.php index be64283..0ec88f9 100644 --- a/Render/Html/GetNelmioAsset.php +++ b/Render/Html/GetNelmioAsset.php @@ -31,7 +31,7 @@ class GetNelmioAsset extends AbstractExtension $this->resourcesDir = __DIR__.'/../../Resources/public'; } - public function getFunctions() + public function getFunctions(): array { return [ new TwigFunction('nelmioAsset', $this, ['is_safe' => ['html']]),