Commit 5ce31a08 authored by Jakub Konečný's avatar Jakub Konečný

updated dependencies

parent 5322e9d8
Pipeline #115687545 failed with stage
in 51 seconds
...@@ -2,6 +2,7 @@ includes: ...@@ -2,6 +2,7 @@ includes:
- vendor/nexendrie/code-quality/phpstan.neon - vendor/nexendrie/code-quality/phpstan.neon
- vendor/phpstan/phpstan-strict-rules/rules.neon - vendor/phpstan/phpstan-strict-rules/rules.neon
parameters: parameters:
checkMissingIterableValueType: false
autoload_files: autoload_files:
- %rootDir%/../../../src/functions.php - %rootDir%/../../../src/functions.php
ignoreErrors: ignoreErrors:
......
...@@ -130,7 +130,7 @@ final class Generator { ...@@ -130,7 +130,7 @@ final class Generator {
"styles" => [], "styles" => [],
"scripts" => [], "scripts" => [],
]); ]);
$isArrayOfStrings = function(array $value) { $isArrayOfStrings = function(array $value): bool {
return Validators::everyIs($value, "string"); return Validators::everyIs($value, "string");
}; };
$resolver->setAllowedTypes("title", "string"); $resolver->setAllowedTypes("title", "string");
...@@ -176,7 +176,7 @@ final class Generator { ...@@ -176,7 +176,7 @@ final class Generator {
} }
protected function removeInvalidFiles(array &$input, string $basePath): void { protected function removeInvalidFiles(array &$input, string $basePath): void {
$input = array_filter($input, function($value) use($basePath) { $input = array_filter($input, function($value) use($basePath): bool {
return file_exists("$basePath/$value"); return file_exists("$basePath/$value");
}); });
} }
...@@ -190,7 +190,7 @@ final class Generator { ...@@ -190,7 +190,7 @@ final class Generator {
%%styles%%", "", $html); %%styles%%", "", $html);
return; return;
} }
array_walk($meta["styles"], function(&$value) use($basePath) { array_walk($meta["styles"], function(&$value) use($basePath): void {
$this->addAsset("$basePath/$value"); $this->addAsset("$basePath/$value");
$value = "<link rel=\"stylesheet\" type=\"text/css\" href=\"$value\">"; $value = "<link rel=\"stylesheet\" type=\"text/css\" href=\"$value\">";
}); });
...@@ -206,7 +206,7 @@ final class Generator { ...@@ -206,7 +206,7 @@ final class Generator {
%%scripts%%", "", $html); %%scripts%%", "", $html);
return; return;
} }
array_walk($meta["scripts"], function(&$value) use($basePath) { array_walk($meta["scripts"], function(&$value) use($basePath): void {
$this->addAsset("$basePath/$value"); $this->addAsset("$basePath/$value");
$value = "<script type=\"text/javascript\" src=\"$value\"></script>"; $value = "<script type=\"text/javascript\" src=\"$value\"></script>";
}); });
...@@ -215,7 +215,7 @@ final class Generator { ...@@ -215,7 +215,7 @@ final class Generator {
protected function updateLinks(array &$meta, string &$html, string $filename): void { protected function updateLinks(array &$meta, string &$html, string $filename): void {
$dom = new \DOMDocument(); $dom = new \DOMDocument();
set_error_handler(function($errno) { set_error_handler(function($errno): bool {
return $errno === E_WARNING; return $errno === E_WARNING;
}); });
$dom->loadHTML($html); $dom->loadHTML($html);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment