Moved error handler classes from Expressive namespace to ErrorHandler namespace

This commit is contained in:
Alejandro Celaya 2016-07-30 13:51:52 +02:00
parent 2a018f5415
commit e345c2bbfe
11 changed files with 15 additions and 16 deletions

View File

@ -1,6 +1,6 @@
<?php
use Shlinkio\Shlink\Common\Expressive\ContentBasedErrorHandler;
use Shlinkio\Shlink\Common\ErrorHandler\ContentBasedErrorHandler;
use Zend\Expressive\Container\WhoopsErrorHandlerFactory;
return [

View File

@ -1,8 +1,5 @@
<?php
use Acelaya\ZsmAnnotatedServices\Factory\V3\AnnotatedFactory;
use Shlinkio\Shlink\Common\Expressive\ContentBasedErrorHandler;
use Shlinkio\Shlink\Common\Expressive\ErrorHandlerManager;
use Shlinkio\Shlink\Common\Expressive\ErrorHandlerManagerFactory;
use Shlinkio\Shlink\Common\ErrorHandler\ContentBasedErrorHandler;
use Zend\Expressive;
use Zend\Expressive\Container;
use Zend\Expressive\Helper;
@ -25,8 +22,6 @@ return [
Router\FastRouteRouter::class => InvokableFactory::class,
// View
ContentBasedErrorHandler::class => AnnotatedFactory::class,
ErrorHandlerManager::class => ErrorHandlerManagerFactory::class,
Template\TemplateRendererInterface::class => Twig\TwigRendererFactory::class,
],
'aliases' => [

View File

@ -1,5 +1,5 @@
<?php
use Shlinkio\Shlink\Common\Expressive\ContentBasedErrorHandler;
use Shlinkio\Shlink\Common\ErrorHandler\ContentBasedErrorHandler;
use Zend\Expressive\Container\TemplatedErrorHandlerFactory;
use Zend\Stratigility\FinalHandler;

View File

@ -2,6 +2,7 @@
use Acelaya\ZsmAnnotatedServices\Factory\V3\AnnotatedFactory;
use Doctrine\Common\Cache\Cache;
use Doctrine\ORM\EntityManager;
use Shlinkio\Shlink\Common\ErrorHandler;
use Shlinkio\Shlink\Common\Factory\CacheFactory;
use Shlinkio\Shlink\Common\Factory\EntityManagerFactory;
use Shlinkio\Shlink\Common\Factory\TranslatorFactory;
@ -22,6 +23,9 @@ return [
Translator::class => TranslatorFactory::class,
TranslatorExtension::class => AnnotatedFactory::class,
LocaleMiddleware::class => AnnotatedFactory::class,
ErrorHandler\ContentBasedErrorHandler::class => AnnotatedFactory::class,
ErrorHandler\ErrorHandlerManager::class => ErrorHandler\ErrorHandlerManagerFactory::class,
],
'aliases' => [
'em' => EntityManager::class,

View File

@ -1,5 +1,5 @@
<?php
namespace Shlinkio\Shlink\Common\Expressive;
namespace Shlinkio\Shlink\Common\ErrorHandler;
use Acelaya\ZsmAnnotatedServices\Annotation\Inject;
use Psr\Http\Message\ResponseInterface as Response;

View File

@ -1,5 +1,5 @@
<?php
namespace Shlinkio\Shlink\Common\Expressive;
namespace Shlinkio\Shlink\Common\ErrorHandler;
use Psr\Http\Message\ServerRequestInterface as Request;
use Psr\Http\Message\ResponseInterface as Response;

View File

@ -1,5 +1,5 @@
<?php
namespace Shlinkio\Shlink\Common\Expressive;
namespace Shlinkio\Shlink\Common\ErrorHandler;
use Zend\ServiceManager\AbstractPluginManager;
use Zend\ServiceManager\Exception\InvalidServiceException;

View File

@ -1,5 +1,5 @@
<?php
namespace Shlinkio\Shlink\Common\Expressive;
namespace Shlinkio\Shlink\Common\ErrorHandler;
use Interop\Container\ContainerInterface;
use Interop\Container\Exception\ContainerException;

View File

@ -1,5 +1,5 @@
<?php
namespace Shlinkio\Shlink\Common\Expressive;
namespace Shlinkio\Shlink\Common\ErrorHandler;
use Interop\Container\ContainerInterface;

View File

@ -1,5 +1,5 @@
<?php
use Shlinkio\Shlink\Rest\Expressive\JsonErrorHandler;
use Shlinkio\Shlink\Rest\ErrorHandler\JsonErrorHandler;
return [

View File

@ -1,9 +1,9 @@
<?php
namespace Shlinkio\Shlink\Rest\Expressive;
namespace Shlinkio\Shlink\Rest\ErrorHandler;
use Psr\Http\Message\ServerRequestInterface as Request;
use Psr\Http\Message\ResponseInterface as Response;
use Shlinkio\Shlink\Common\Expressive\ErrorHandlerInterface;
use Shlinkio\Shlink\Common\ErrorHandler\ErrorHandlerInterface;
use Zend\Diactoros\Response\JsonResponse;
use Zend\Expressive\Router\RouteResult;