Use a proper DI system

master
Mike Koch 7 years ago
parent 7ca00fecbe
commit be42fe04fb
No known key found for this signature in database
GPG Key ID: 9BA5D7F8391455ED

@ -1,127 +0,0 @@
<?php
// Responsible for loading in all necessary classes. AKA a poor man's DI solution.
use BusinessLogic\Attachments\AttachmentHandler;
use BusinessLogic\Attachments\AttachmentRetriever;
use BusinessLogic\Categories\CategoryHandler;
use BusinessLogic\Categories\CategoryRetriever;
use BusinessLogic\Emails\BasicEmailSender;
use BusinessLogic\Emails\EmailSenderHelper;
use BusinessLogic\Emails\EmailTemplateParser;
use BusinessLogic\Emails\EmailTemplateRetriever;
use BusinessLogic\Emails\MailgunEmailSender;
use BusinessLogic\Navigation\CustomNavElementHandler;
use BusinessLogic\Security\BanRetriever;
use BusinessLogic\Security\PermissionChecker;
use BusinessLogic\Security\UserContextBuilder;
use BusinessLogic\Security\UserToTicketChecker;
use BusinessLogic\Settings\ApiChecker;
use BusinessLogic\Settings\SettingsRetriever;
use BusinessLogic\Statuses\StatusRetriever;
use BusinessLogic\Tickets\Autoassigner;
use BusinessLogic\Tickets\TicketDeleter;
use BusinessLogic\Tickets\TicketEditor;
use BusinessLogic\Tickets\TicketRetriever;
use BusinessLogic\Tickets\TicketCreator;
use BusinessLogic\Tickets\NewTicketValidator;
use BusinessLogic\Tickets\TicketValidators;
use BusinessLogic\Tickets\TrackingIdGenerator;
use BusinessLogic\Tickets\VerifiedEmailChecker;
use DataAccess\Attachments\AttachmentGateway;
use DataAccess\Categories\CategoryGateway;
use DataAccess\Files\FileDeleter;
use DataAccess\Files\FileReader;
use DataAccess\Files\FileWriter;
use DataAccess\Logging\LoggingGateway;
use DataAccess\Navigation\CustomNavElementGateway;
use DataAccess\Security\BanGateway;
use DataAccess\Security\UserGateway;
use DataAccess\Settings\ModsForHeskSettingsGateway;
use DataAccess\Statuses\StatusGateway;
use DataAccess\Tickets\TicketGateway;
use DataAccess\Tickets\VerifiedEmailGateway;
class ApplicationContext {
public $get;
/**
* ApplicationContext constructor.
*/
function __construct() {
$this->get = array();
$this->get[PermissionChecker::class] = new PermissionChecker();
$this->get[ModsForHeskSettingsGateway::class] = new ModsForHeskSettingsGateway();
$this->get[CustomNavElementGateway::class] = new CustomNavElementGateway();
$this->get[LoggingGateway::class] = new LoggingGateway();
$this->get[VerifiedEmailGateway::class] = new VerifiedEmailGateway();
$this->get[UserGateway::class] = new UserGateway();
$this->get[CategoryGateway::class] = new CategoryGateway();
$this->get[BanGateway::class] = new BanGateway();
$this->get[StatusGateway::class] = new StatusGateway();
$this->get[BasicEmailSender::class] = new BasicEmailSender();
$this->get[MailgunEmailSender::class] = new MailgunEmailSender();
$this->get[EmailTemplateRetriever::class] = new EmailTemplateRetriever();
$this->get[TicketGateway::class] = new TicketGateway();
$this->get[FileWriter::class] = new FileWriter();
$this->get[FileReader::class] = new FileReader();
$this->get[FileDeleter::class] = new FileDeleter();
$this->get[AttachmentGateway::class] = new AttachmentGateway();
$this->get[ApiChecker::class] = new ApiChecker($this->get[ModsForHeskSettingsGateway::class]);
$this->get[CustomNavElementHandler::class] = new CustomNavElementHandler($this->get[CustomNavElementGateway::class]);
$this->get[VerifiedEmailChecker::class] = new VerifiedEmailChecker($this->get[VerifiedEmailGateway::class]);
$this->get[UserContextBuilder::class] = new UserContextBuilder($this->get[UserGateway::class]);
$this->get[BanRetriever::class] = new BanRetriever($this->get[BanGateway::class]);
$this->get[UserToTicketChecker::class] = new UserToTicketChecker($this->get[UserGateway::class]);
$this->get[StatusRetriever::class] = new StatusRetriever($this->get[StatusGateway::class]);
$this->get[SettingsRetriever::class] = new SettingsRetriever($this->get[ModsForHeskSettingsGateway::class]);
$this->get[TicketValidators::class] = new TicketValidators($this->get[TicketGateway::class]);
$this->get[TrackingIdGenerator::class] = new TrackingIdGenerator($this->get[TicketGateway::class]);
$this->get[Autoassigner::class] = new Autoassigner($this->get[CategoryGateway::class], $this->get[UserGateway::class]);
$this->get[CategoryRetriever::class] = new CategoryRetriever($this->get[CategoryGateway::class],
$this->get[ModsForHeskSettingsGateway::class]);
$this->get[CategoryHandler::class] = new CategoryHandler(
$this->get[CategoryGateway::class],
$this->get[TicketGateway::class],
$this->get[PermissionChecker::class],
$this->get[ModsForHeskSettingsGateway::class]);
$this->get[EmailTemplateParser::class] = new EmailTemplateParser($this->get[StatusGateway::class],
$this->get[CategoryGateway::class],
$this->get[UserGateway::class],
$this->get[EmailTemplateRetriever::class]);
$this->get[EmailSenderHelper::class] = new EmailSenderHelper($this->get[EmailTemplateParser::class],
$this->get[BasicEmailSender::class],
$this->get[MailgunEmailSender::class]);
$this->get[TicketRetriever::class] = new TicketRetriever($this->get[TicketGateway::class],
$this->get[UserToTicketChecker::class]);
$this->get[NewTicketValidator::class] = new NewTicketValidator($this->get[CategoryRetriever::class],
$this->get[BanRetriever::class],
$this->get[TicketValidators::class]);
$this->get[TicketCreator::class] = new TicketCreator($this->get[NewTicketValidator::class],
$this->get[TrackingIdGenerator::class],
$this->get[Autoassigner::class],
$this->get[StatusGateway::class],
$this->get[TicketGateway::class],
$this->get[VerifiedEmailChecker::class],
$this->get[EmailSenderHelper::class],
$this->get[UserGateway::class],
$this->get[ModsForHeskSettingsGateway::class]);
$this->get[AttachmentHandler::class] = new AttachmentHandler($this->get[TicketGateway::class],
$this->get[AttachmentGateway::class],
$this->get[FileWriter::class],
$this->get[UserToTicketChecker::class],
$this->get[FileDeleter::class]);
$this->get[AttachmentRetriever::class] = new AttachmentRetriever($this->get[AttachmentGateway::class],
$this->get[FileReader::class],
$this->get[TicketGateway::class],
$this->get[UserToTicketChecker::class]);
$this->get[TicketDeleter::class] =
new TicketDeleter($this->get[TicketGateway::class],
$this->get[UserToTicketChecker::class],
$this->get[AttachmentHandler::class]);
$this->get[TicketEditor::class] =
new TicketEditor($this->get[TicketGateway::class], $this->get[UserToTicketChecker::class]);
}
}

@ -14,7 +14,7 @@ class PublicAttachmentController {
self::verifyAttachmentsAreEnabled($hesk_settings);
/* @var $attachmentRetriever AttachmentRetriever */
$attachmentRetriever = $applicationContext->get[AttachmentRetriever::class];
$attachmentRetriever = $applicationContext->get(AttachmentRetriever::class);
$attachment = $attachmentRetriever->getAttachmentContentsForTrackingId($trackingId, $attachmentId, $userContext, $hesk_settings);

@ -18,7 +18,7 @@ class StaffTicketAttachmentsController {
$this->verifyAttachmentsAreEnabled($hesk_settings);
/* @var $attachmentRetriever AttachmentRetriever */
$attachmentRetriever = $applicationContext->get[AttachmentRetriever::class];
$attachmentRetriever = $applicationContext->get(AttachmentRetriever::class);
$contents = $attachmentRetriever->getAttachmentContentsForTicket($ticketId, $attachmentId, $userContext, $hesk_settings);
@ -37,7 +37,7 @@ class StaffTicketAttachmentsController {
$this->verifyAttachmentsAreEnabled($hesk_settings);
/* @var $attachmentHandler AttachmentHandler */
$attachmentHandler = $applicationContext->get[AttachmentHandler::class];
$attachmentHandler = $applicationContext->get(AttachmentHandler::class);
$createAttachmentForTicketModel = $this->createModel(JsonRetriever::getJsonData(), $ticketId);
@ -61,7 +61,7 @@ class StaffTicketAttachmentsController {
global $applicationContext, $hesk_settings, $userContext;
/* @var $attachmentHandler AttachmentHandler */
$attachmentHandler = $applicationContext->get[AttachmentHandler::class];
$attachmentHandler = $applicationContext->get(AttachmentHandler::class);
$attachmentHandler->deleteAttachmentFromTicket($ticketId, $attachmentId, $userContext, $hesk_settings);

@ -30,7 +30,7 @@ class CategoryController {
global $hesk_settings, $applicationContext, $userContext;
/* @var $categoryRetriever CategoryRetriever */
$categoryRetriever = $applicationContext->get[CategoryRetriever::class];
$categoryRetriever = $applicationContext->get(CategoryRetriever::class);
return $categoryRetriever->getAllCategories($hesk_settings, $userContext);
}
@ -43,7 +43,7 @@ class CategoryController {
$category = $this->buildCategoryFromJson($data);
/* @var $categoryHandler CategoryHandler */
$categoryHandler = $applicationContext->get[CategoryHandler::class];
$categoryHandler = $applicationContext->get(CategoryHandler::class);
$category = $categoryHandler->createCategory($category, $userContext, $hesk_settings);
@ -81,7 +81,7 @@ class CategoryController {
$category->id = intval($id);
/* @var $categoryHandler CategoryHandler */
$categoryHandler = $applicationContext->get[CategoryHandler::class];
$categoryHandler = $applicationContext->get(CategoryHandler::class);
$category = $categoryHandler->editCategory($category, $userContext, $hesk_settings);
@ -92,7 +92,7 @@ class CategoryController {
global $hesk_settings, $userContext, $applicationContext;
/* @var $categoryHandler CategoryHandler */
$categoryHandler = $applicationContext->get[CategoryHandler::class];
$categoryHandler = $applicationContext->get(CategoryHandler::class);
$categoryHandler->deleteCategory($id, $userContext, $hesk_settings);
@ -103,7 +103,7 @@ class CategoryController {
global $applicationContext, $hesk_settings;
/* @var $handler CategoryHandler */
$handler = $applicationContext->get[CategoryHandler::class];
$handler = $applicationContext->get(CategoryHandler::class);
$handler->sortCategory(intval($id), $direction, $hesk_settings);
}

@ -3,7 +3,6 @@
namespace Controllers\Navigation;
use BusinessLogic\Exceptions\ApiFriendlyException;
use BusinessLogic\Helpers;
use BusinessLogic\Navigation\CustomNavElement;
use BusinessLogic\Navigation\CustomNavElementHandler;
@ -17,7 +16,7 @@ class CustomNavElementController extends InternalApiController {
self::staticCheckForInternalUseOnly();
/* @var $handler CustomNavElementHandler */
$handler = $applicationContext->get[CustomNavElementHandler::class];
$handler = $applicationContext->get(CustomNavElementHandler::class);
output($handler->getAllCustomNavElements($hesk_settings));
}
@ -28,7 +27,7 @@ class CustomNavElementController extends InternalApiController {
self::staticCheckForInternalUseOnly();
/* @var $handler CustomNavElementHandler */
$handler = $applicationContext->get[CustomNavElementHandler::class];
$handler = $applicationContext->get(CustomNavElementHandler::class);
$handler->sortCustomNavElement(intval($id), $direction, $hesk_settings);
}
@ -39,7 +38,7 @@ class CustomNavElementController extends InternalApiController {
$this->checkForInternalUseOnly();
/* @var $handler CustomNavElementHandler */
$handler = $applicationContext->get[CustomNavElementHandler::class];
$handler = $applicationContext->get(CustomNavElementHandler::class);
output($handler->getCustomNavElement($id, $hesk_settings));
}
@ -50,7 +49,7 @@ class CustomNavElementController extends InternalApiController {
$this->checkForInternalUseOnly();
/* @var $handler CustomNavElementHandler */
$handler = $applicationContext->get[CustomNavElementHandler::class];
$handler = $applicationContext->get(CustomNavElementHandler::class);
$data = JsonRetriever::getJsonData();
$element = $handler->createCustomNavElement($this->buildElementModel($data), $hesk_settings);
@ -64,7 +63,7 @@ class CustomNavElementController extends InternalApiController {
$this->checkForInternalUseOnly();
/* @var $handler CustomNavElementHandler */
$handler = $applicationContext->get[CustomNavElementHandler::class];
$handler = $applicationContext->get(CustomNavElementHandler::class);
$data = JsonRetriever::getJsonData();
$handler->saveCustomNavElement($this->buildElementModel($data, $id), $hesk_settings);
@ -78,7 +77,7 @@ class CustomNavElementController extends InternalApiController {
$this->checkForInternalUseOnly();
/* @var $handler CustomNavElementHandler */
$handler = $applicationContext->get[CustomNavElementHandler::class];
$handler = $applicationContext->get(CustomNavElementHandler::class);
$handler->deleteCustomNavElement($id, $hesk_settings);

@ -7,11 +7,11 @@ use BusinessLogic\Settings\SettingsRetriever;
class SettingsController {
function get() {
global $applicationContext, $hesk_settings, $modsForHesk_settings;
global $applicationContext, $hesk_settings;
/* @var $settingsRetriever SettingsRetriever */
$settingsRetriever = $applicationContext->get[SettingsRetriever::class];
$settingsRetriever = $applicationContext->get(SettingsRetriever::class);
output($settingsRetriever->getAllSettings($hesk_settings, $modsForHesk_settings));
output($settingsRetriever->getAllSettings($hesk_settings));
}
}

@ -10,7 +10,7 @@ class StatusController {
global $applicationContext, $hesk_settings;
/* @var $statusRetriever StatusRetriever */
$statusRetriever = $applicationContext->get[StatusRetriever::class];
$statusRetriever = $applicationContext->get(StatusRetriever::class);
output($statusRetriever->getAllStatuses($hesk_settings));
}

@ -18,7 +18,7 @@ class CustomerTicketController {
$emailAddress = isset($_GET['email']) ? $_GET['email'] : null;
/* @var $ticketRetriever TicketRetriever */
$ticketRetriever = $applicationContext->get[TicketRetriever::class];
$ticketRetriever = $applicationContext->get(TicketRetriever::class);
output($ticketRetriever->getTicketByTrackingIdAndEmail($trackingId, $emailAddress, $hesk_settings));
}
@ -27,7 +27,7 @@ class CustomerTicketController {
global $applicationContext, $hesk_settings, $userContext;
/* @var $ticketCreator TicketCreator */
$ticketCreator = $applicationContext->get[TicketCreator::class];
$ticketCreator = $applicationContext->get(TicketCreator::class);
$jsonRequest = JsonRetriever::getJsonData();

@ -19,15 +19,15 @@ class ResendTicketEmailToCustomerController extends InternalApiController {
$this->checkForInternalUseOnly();
/* @var $ticketRetriever TicketRetriever */
$ticketRetriever = $applicationContext->get[TicketRetriever::class];
$ticketRetriever = $applicationContext->get(TicketRetriever::class);
$ticket = $ticketRetriever->getTicketById($ticketId, $hesk_settings, $userContext);
/* @var $modsForHeskSettingsGateway ModsForHeskSettingsGateway */
$modsForHeskSettingsGateway = $applicationContext->get[ModsForHeskSettingsGateway::class];
$modsForHeskSettingsGateway = $applicationContext->get(ModsForHeskSettingsGateway::class);
$modsForHeskSettings = $modsForHeskSettingsGateway->getAllSettings($hesk_settings);
/* @var $emailSender EmailSenderHelper */
$emailSender = $applicationContext->get[EmailSenderHelper::class];
$emailSender = $applicationContext->get(EmailSenderHelper::class);
$language = $ticket->language;

@ -15,7 +15,7 @@ class StaffTicketController {
global $applicationContext, $userContext, $hesk_settings;
/* @var $ticketRetriever TicketRetriever */
$ticketRetriever = $applicationContext->get[TicketRetriever::class];
$ticketRetriever = $applicationContext->get(TicketRetriever::class);
output($ticketRetriever->getTicketById($id, $hesk_settings, $userContext));
}
@ -24,7 +24,7 @@ class StaffTicketController {
global $applicationContext, $userContext, $hesk_settings;
/* @var $ticketDeleter TicketDeleter */
$ticketDeleter = $applicationContext->get[TicketDeleter::class];
$ticketDeleter = $applicationContext->get(TicketDeleter::class);
$ticketDeleter->deleteTicket($id, $userContext, $hesk_settings);
@ -35,7 +35,7 @@ class StaffTicketController {
global $applicationContext, $userContext, $hesk_settings;
/* @var $ticketEditor TicketEditor */
$ticketEditor = $applicationContext->get[TicketEditor::class];
$ticketEditor = $applicationContext->get(TicketEditor::class);
$jsonRequest = JsonRetriever::getJsonData();

@ -21,4 +21,7 @@ global $hesk_settings;
require_once(__DIR__ . '/../inc/custom_fields.inc.php');
// Load the ApplicationContext
$applicationContext = new \ApplicationContext();
$builder = new \DI\ContainerBuilder();
$builder->setDefinitionCache(new \Doctrine\Common\Cache\ArrayCache());
$applicationContext = $builder->build();

@ -12,6 +12,12 @@
"require-dev": {
"phpunit/phpunit": "6.3.0"
},
"repositories": [
{
"type": "vcs",
"url": "https://github.com/mike-koch/PHP-DI"
}
],
"require": {
"phpmailer/phpmailer": "^5.2",
"mailgun/mailgun-php": "^2.1",
@ -19,6 +25,6 @@
"php-http/message": "^1.5",
"php-http/curl-client": "^1.7",
"guzzlehttp/psr7": "^1.3",
"php-di/php-di": "4.4.10"
"php-di/php-di": "dev-master"
}
}

44
api/composer.lock generated

@ -4,7 +4,7 @@
"Read more about it at https://getcomposer.org/doc/01-basic-usage.md#composer-lock-the-lock-file",
"This file is @generated automatically"
],
"content-hash": "d7d3d7ef4a481f28ec59f1218cbc9a1a",
"content-hash": "c94a62f4b72739c52334647f4b759251",
"packages": [
{
"name": "clue/stream-filter",
@ -624,16 +624,16 @@
},
{
"name": "php-di/php-di",
"version": "4.4.10",
"version": "dev-master",
"source": {
"type": "git",
"url": "https://github.com/PHP-DI/PHP-DI.git",
"reference": "cc10862b66267b6e6f793eda2867b0aef5b693be"
"url": "https://github.com/mike-koch/PHP-DI.git",
"reference": "02ae2f2f79f3c09f711f8936e2c69cc65a530f1b"
},
"dist": {
"type": "zip",
"url": "https://api.github.com/repos/PHP-DI/PHP-DI/zipball/cc10862b66267b6e6f793eda2867b0aef5b693be",
"reference": "cc10862b66267b6e6f793eda2867b0aef5b693be",
"url": "https://api.github.com/repos/mike-koch/PHP-DI/zipball/02ae2f2f79f3c09f711f8936e2c69cc65a530f1b",
"reference": "02ae2f2f79f3c09f711f8936e2c69cc65a530f1b",
"shasum": ""
},
"require": {
@ -657,7 +657,12 @@
"src/DI/functions.php"
]
},
"notification-url": "https://packagist.org/downloads/",
"autoload-dev": {
"psr-4": {
"DI\\Test\\IntegrationTest\\": "tests/IntegrationTest/",
"DI\\Test\\UnitTest\\": "tests/UnitTest/"
}
},
"license": [
"MIT"
],
@ -668,7 +673,10 @@
"dependency injection",
"di"
],
"time": "2015-07-24T09:21:24+00:00"
"support": {
"source": "https://github.com/mike-koch/PHP-DI/tree/master"
},
"time": "2017-09-08 02:07:52"
},
{
"name": "php-di/phpdoc-reader",
@ -1767,7 +1775,7 @@
}
],
"description": "Component for reading phar.io manifest information from a PHP Archive (PHAR)",
"time": "2017-04-07T07:07:10+00:00"
"time": "2017-04-07 07:07:10"
},
{
"name": "phar-io/version",
@ -2087,7 +2095,7 @@
"testing",
"xunit"
],
"time": "2017-08-25T06:32:04+00:00"
"time": "2017-08-25 06:32:04"
},
{
"name": "phpunit/php-file-iterator",
@ -2416,7 +2424,7 @@
"mock",
"xunit"
],
"time": "2017-08-03T14:08:16+00:00"
"time": "2017-08-03 14:08:16"
},
{
"name": "sebastian/code-unit-reverse-lookup",
@ -2525,7 +2533,7 @@
"compare",
"equality"
],
"time": "2017-08-20T14:03:32+00:00"
"time": "2017-08-20 14:03:32"
},
{
"name": "sebastian/diff",
@ -2627,7 +2635,7 @@
"environment",
"hhvm"
],
"time": "2017-07-01T08:51:00+00:00"
"time": "2017-07-01 08:51:00"
},
{
"name": "sebastian/exporter",
@ -2694,7 +2702,7 @@
"export",
"exporter"
],
"time": "2017-04-03T13:19:02+00:00"
"time": "2017-04-03 13:19:02"
},
{
"name": "sebastian/global-state",
@ -2792,7 +2800,7 @@
],
"description": "Traverses array structures and object graphs to enumerate all referenced objects",
"homepage": "https://github.com/sebastianbergmann/object-enumerator/",
"time": "2017-08-03T12:35:26+00:00"
"time": "2017-08-03 12:35:26"
},
{
"name": "sebastian/object-reflector",
@ -2837,7 +2845,7 @@
],
"description": "Allows reflection of object attributes, including inherited and non-public ones",
"homepage": "https://github.com/sebastianbergmann/object-reflector/",
"time": "2017-03-29T09:07:27+00:00"
"time": "2017-03-29 09:07:27"
},
{
"name": "sebastian/recursion-context",
@ -3020,7 +3028,9 @@
],
"aliases": [],
"minimum-stability": "dev",
"stability-flags": [],
"stability-flags": {
"php-di/php-di": 20
},
"prefer-stable": false,
"prefer-lowest": false,
"platform": [],

@ -50,7 +50,7 @@ function assertApiIsEnabled() {
global $applicationContext, $hesk_settings;
/* @var $apiChecker \BusinessLogic\Settings\ApiChecker */
$apiChecker = $applicationContext->get[\BusinessLogic\Settings\ApiChecker::class];
$apiChecker = $applicationContext->get(\BusinessLogic\Settings\ApiChecker::class);
if (!$apiChecker->isApiEnabled($hesk_settings)) {
print output(array('message' => 'API Disabled'), 404);
@ -77,7 +77,7 @@ function buildUserContext($xAuthToken) {
global $applicationContext, $userContext, $hesk_settings;
/* @var $userContextBuilder \BusinessLogic\Security\UserContextBuilder */
$userContextBuilder = $applicationContext->get[\BusinessLogic\Security\UserContextBuilder::class];
$userContextBuilder = $applicationContext->get(\BusinessLogic\Security\UserContextBuilder::class);
$userContext = $userContextBuilder->buildUserContext($xAuthToken, $hesk_settings);
}
@ -90,17 +90,13 @@ function errorHandler($errorNumber, $errorMessage, $errorFile, $errorLine) {
* @param $exception Exception
*/
function exceptionHandler($exception) {
global $applicationContext, $userContext, $hesk_settings;
global $userContext, $hesk_settings;
if (strpos($exception->getTraceAsString(), 'LoggingGateway') !== false) {
//-- Suppress these for now, as it would cause issues to output two JSONs at one time.
return;
}
/* @var $loggingGateway \DataAccess\Logging\LoggingGateway */
$loggingGateway = $applicationContext->get[\DataAccess\Logging\LoggingGateway::class];
// We don't cast API Friendly Exceptions as they're user-generated errors
if (exceptionIsOfType($exception, \BusinessLogic\Exceptions\ApiFriendlyException::class)) {
/* @var $castedException \BusinessLogic\Exceptions\ApiFriendlyException */
@ -142,7 +138,7 @@ function tryToLog($location, $message, $stackTrace, $userContext, $heskSettings)
global $applicationContext;
/* @var $loggingGateway \DataAccess\Logging\LoggingGateway */
$loggingGateway = $applicationContext->get[\DataAccess\Logging\LoggingGateway::class];
$loggingGateway = $applicationContext->get(\DataAccess\Logging\LoggingGateway::class);
try {
return $loggingGateway->logError($location, $message, $stackTrace, $userContext, $heskSettings);

Loading…
Cancel
Save