diff --git a/src/Console/Commands/CheckIfTranslationsAreAllThereCommand.php b/src/Console/Commands/CheckIfTranslationsAreAllThereCommand.php index 9b70a79..1bded09 100644 --- a/src/Console/Commands/CheckIfTranslationsAreAllThereCommand.php +++ b/src/Console/Commands/CheckIfTranslationsAreAllThereCommand.php @@ -79,6 +79,10 @@ public function handle() $languagesWithMissingFile = $this->checkIfFileExistsForOtherLanguages($languages, $fileName, $directory); + if ($this->isDirInExcludedDirectories($languageDir)) { + continue; + } + foreach ($languagesWithMissingFile as $languageWithMissingFile) { if ($this->isDirInExcludedDirectories($languageWithMissingFile)) { continue; @@ -199,6 +203,12 @@ private function checkIfFileExistsForOtherLanguages($languages, $fileName, $base private function isDirInExcludedDirectories($directoryToCheck): bool { - return in_array($directoryToCheck, $this->excludedDirectories, true); + foreach($this->excludedDirectories as $excludedDirectory) { + if(Str::contains($directoryToCheck, $excludedDirectory)) { + return true; + } + } + + return false; } }