Skip system files when finding content files
This commit is contained in:
parent
b507a0c676
commit
eda800d048
1 changed files with 3 additions and 0 deletions
|
|
@ -60,6 +60,9 @@ function findAllContentFiles(string $dir, string $lang, string $defaultLang): ar
|
|||
foreach ($files as $file) {
|
||||
if ($file === '.' || $file === '..') continue;
|
||||
|
||||
// Exclude system files from content
|
||||
if ($file === 'index.php') continue;
|
||||
|
||||
$ext = pathinfo($file, PATHINFO_EXTENSION);
|
||||
if (!in_array($ext, $extensions)) continue;
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue