* updated expressive version

This commit is contained in:
Danyi Dávid
2018-11-12 07:09:32 +01:00
parent 17ec066110
commit d77a3e4211
109 changed files with 5980 additions and 2606 deletions

View File

@@ -7,6 +7,7 @@
return [
'acl_config' => [
'unguarded_routes' => [
'home',
'api.auth.login',
'api.ping',
'api.xlsx',

View File

@@ -6,14 +6,14 @@ return [
'factories' => [
App\Command\InitializeFixtureCommand::class => App\Command\InitializeFixtureCommandFactory::class,
// App\Command\ConvertMaintenanceHashCommand::class => App\Command\ConvertMaintenanceHashCommandFactory::class,
// App\Command\MailTestCommand::class => App\Command\MailTestCommandFactory::class,
// App\Command\DebugMailCommand::class => App\Command\DebugMailCommandFactory::class,
],
],
'console' => [
'commands' => [
App\Command\InitializeFixtureCommand::class,
// App\Command\ConvertMaintenanceHashCommand::class,
// App\Command\MailTestCommand::class,
// App\Command\DebugMailCommand::class,
],
],
];

View File

@@ -1,10 +1,6 @@
<?php
use Zend\Expressive\Application;
use Zend\Expressive\Container;
use Zend\Expressive\Delegate;
use Zend\Expressive\Helper;
use Zend\Expressive\Middleware;
declare(strict_types=1);
return [
// Provides application-wide services.
@@ -14,30 +10,19 @@ return [
// Use 'aliases' to alias a service name to another service. The
// key is the alias name, the value is the service to which it points.
'aliases' => [
'Zend\Expressive\Delegate\DefaultDelegate' => Delegate\NotFoundDelegate::class,
// Fully\Qualified\ClassOrInterfaceName::class => Fully\Qualified\ClassName::class,
],
// Use 'invokables' for constructor-less services, or services that do
// not require arguments to the constructor. Map a service name to the
// class name.
'invokables' => [
// Fully\Qualified\InterfaceName::class => Fully\Qualified\ClassName::class,
Helper\ServerUrlHelper::class => Helper\ServerUrlHelper::class,
],
// Use 'factories' for services provided by callbacks/factory classes.
'factories' => [
Application::class => Container\ApplicationFactory::class,
Delegate\NotFoundDelegate::class => Container\NotFoundDelegateFactory::class,
Helper\ServerUrlMiddleware::class => Helper\ServerUrlMiddlewareFactory::class,
Helper\UrlHelper::class => Helper\UrlHelperFactory::class,
Helper\UrlHelperMiddleware::class => Helper\UrlHelperMiddlewareFactory::class,
Zend\Stratigility\Middleware\ErrorHandler::class => Container\ErrorHandlerFactory::class,
Middleware\ErrorResponseGenerator::class => Container\ErrorResponseGeneratorFactory::class,
Middleware\NotFoundHandler::class => Container\NotFoundHandlerFactory::class,
Slim\Middleware\JwtAuthentication::class => App\Middleware\JwtAuthenticationFactory::class,
Tuupola\Middleware\Cors::class => App\Middleware\CorsMiddlewareFactory::class,
// Fully\Qualified\ClassName::class => Fully\Qualified\FactoryName::class,
App\Middleware\RouteAuthorization::class => App\Middleware\RouteAuthorizationFactory::class,
Tuupola\Middleware\JwtAuthentication::class => App\Middleware\JwtAuthenticationFactory::class,
],
],
];

View File

@@ -1,5 +1,4 @@
<?php
/**
* Development-only configuration.
*
@@ -10,6 +9,8 @@
* `composer development-enable`.
*/
declare(strict_types=1);
use Zend\Expressive\Container;
use Zend\Expressive\Middleware\ErrorResponseGenerator;

View File

@@ -1,12 +1,6 @@
<?php
return [
'dependencies' => [
'factories' => [
'doctrine.entity_manager.orm_default' => ContainerInteropDoctrine\EntityManagerFactory::class,
'doctrine.hydrator' => App\Hydrator\DoctrineObjectFactory::class,
],
],
'doctrine' => [
'driver' => [
'orm_default' => [

View File

@@ -1,12 +0,0 @@
<?php
use Zend\Expressive\Router\FastRouteRouter;
use Zend\Expressive\Router\RouterInterface;
return [
'dependencies' => [
'invokables' => [
RouterInterface::class => FastRouteRouter::class,
],
],
];

View File

@@ -1,5 +1,7 @@
<?php
declare(strict_types=1);
use Zend\ConfigAggregator\ConfigAggregator;
return [
@@ -13,10 +15,6 @@ return [
'debug' => false,
'zend-expressive' => [
// Enable programmatic pipeline: Any `middleware_pipeline` or `routes`
// configuration will be ignored when creating the `Application` instance.
'programmatic_pipeline' => true,
// Provide templates for the error handling middleware to use when
// generating responses.
'error_handler' => [