public function addLocales(ConfigureLocales $event)
    {
        foreach (new DirectoryIterator(__DIR__.'/../../locale') as $file) {
            if ($file->isFile() && in_array($file->getExtension(), ['yml', 'yaml'])) {
                $event->locales->addTranslations($file->getBasename('.'.$file->getExtension()), $file->getPathname());
            }
        }
    }
public function addLocales(ConfigureLocales $event)
    {
        foreach (new DirectoryIterator(__DIR__.'/../../locale') as $file) {
            if ($file->isFile() && in_array($file->getExtension(), ['yml', 'yaml'])) {
                $event->locales->addTranslations($file->getBasename('.'.$file->getExtension()), $file->getPathname());
            }
        }
    }
public function addLocales ( ConfigureLocales $ event ) { foreach ( new DirectoryIterator ( __DIR__ . '/../../locale' ) as $ file ) { if ( $ file -> isFile ( ) && in_array ( $ file -> getExtension ( ) , [ 'yml' , 'yaml' ] ) ) { $ event -> locales -> addTranslations ( $ file -> getBasename ( '.' . $ file -> getExtension ( ) ) , $ file -> getPathname ( ) ) ; } } }
Provides i18n files.

@param ConfigureLocales $event
Provides i18n files .