Add logger for component

This commit is contained in:
Artem Vasilev 2024-03-17 15:09:42 +03:00
parent 2b0045c6db
commit 712e628755

View File

@ -16,6 +16,7 @@ use Joomla\CMS\Component\Router\RouterServiceTrait;
use Joomla\CMS\Extension\BootableExtensionInterface;
use Joomla\CMS\Extension\MVCComponent;
use Joomla\CMS\HTML\HTMLRegistryAwareTrait;
use Joomla\CMS\Log\Log;
use Joomla\CMS\Plugin\PluginHelper;
use Psr\Container\ContainerInterface;
use Webmasterskaya\Component\OauthServer\Administrator\Helper\ComponentHelper;
@ -44,5 +45,13 @@ class Component extends MVCComponent implements
ComponentHelper::registerComponentDependencies();
PluginHelper::importPlugin('oauthserver');
Log::addLogger(
[
'text_file' => 'com_oauthserver.log.php'
],
Log::ALL,
['com_oauthserver']
);
}
}