2022-06-22 10:48:58 +00:00
|
|
|
<?php
|
|
|
|
|
|
|
|
declare(strict_types=1);
|
|
|
|
|
|
|
|
namespace Modules\Api\Rest\V1\Config;
|
|
|
|
|
|
|
|
use CodeIgniter\Config\BaseService;
|
2024-04-28 16:39:01 +00:00
|
|
|
use Modules\Api\Rest\V1\Core\RestApiExceptions;
|
2022-06-22 10:48:58 +00:00
|
|
|
|
|
|
|
class Services extends BaseService
|
|
|
|
{
|
2024-04-28 16:39:01 +00:00
|
|
|
public static function restApiExceptions(bool $getShared = true): RestApiExceptions
|
2022-06-22 10:48:58 +00:00
|
|
|
{
|
|
|
|
if ($getShared) {
|
|
|
|
return static::getSharedInstance('restApiExceptions');
|
|
|
|
}
|
|
|
|
|
2024-04-28 16:39:01 +00:00
|
|
|
return new RestApiExceptions(config('Exceptions'));
|
2022-06-22 10:48:58 +00:00
|
|
|
}
|
|
|
|
}
|