We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
ux:icons:lock
1 parent 58b0eb2 commit 51f5793Copy full SHA for 51f5793
src/Icons/src/Twig/IconFinder.php
@@ -67,12 +67,14 @@ public function icons(): array
67
private function templateFiles(LoaderInterface $loader): iterable
68
{
69
if ($loader instanceof FilesystemLoader) {
70
- $paths = [];
+ $paths = $loader->getPaths();
71
foreach ($loader->getNamespaces() as $namespace) {
72
$paths = [...$paths, ...$loader->getPaths($namespace)];
73
}
74
- foreach ((new Finder())->files()->in($paths)->name('*.twig') as $file) {
75
- yield (string) $file;
+ if ($paths) {
+ foreach ((new Finder())->files()->in($paths)->name('*.twig') as $file) {
76
+ yield (string) $file;
77
+ }
78
79
80
0 commit comments