From d67b145f56649104571ed4d542aaa3bc66442157 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Danyi=20D=C3=A1vid?= Date: Thu, 18 Jan 2018 18:55:57 +0100 Subject: [PATCH] * los baspath added --- composer.json | 1 + composer.lock | 58 +++++++++++++++++--- config/autoload/los-basepath.global.php.dist | 21 +++++++ 3 files changed, 73 insertions(+), 7 deletions(-) create mode 100644 config/autoload/los-basepath.global.php.dist diff --git a/composer.json b/composer.json index c57af4c..b78a41c 100644 --- a/composer.json +++ b/composer.json @@ -10,6 +10,7 @@ "require": { "php": "^7.1", "http-interop/http-middleware": "^0.4.1", + "los/basepath": "^1.0", "roave/security-advisories": "dev-master", "zendframework/zend-component-installer": "^1.0", "zendframework/zend-config": "3.1.0", diff --git a/composer.lock b/composer.lock index dd9d6ef..ed438c4 100644 --- a/composer.lock +++ b/composer.lock @@ -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": "094c0eaf2b10021157346ca1419de4e5", + "content-hash": "6fb0545051f1b3db45bd70bffd15dc3e", "packages": [ { "name": "container-interop/container-interop", @@ -195,6 +195,49 @@ ], "time": "2016-12-28T00:14:17+00:00" }, + { + "name": "los/basepath", + "version": "1.0.1", + "source": { + "type": "git", + "url": "https://github.com/Lansoweb/basepath.git", + "reference": "8a40de843a4c7cf1fdac51d7e33c7dfbcfb08d29" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/Lansoweb/basepath/zipball/8a40de843a4c7cf1fdac51d7e33c7dfbcfb08d29", + "reference": "8a40de843a4c7cf1fdac51d7e33c7dfbcfb08d29", + "shasum": "" + }, + "require": { + "container-interop/container-interop": "~1.1", + "php": "^7.0", + "psr/http-message": "~1.0" + }, + "require-dev": { + "phpunit/phpunit": "^5.0", + "zendframework/zend-diactoros": "^1.0" + }, + "type": "library", + "autoload": { + "psr-4": { + "LosMiddleware\\BasePath\\": "src/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Leandro Silva", + "homepage": "http://leandrosilva.info/" + } + ], + "description": "PHP middleware to remove a path prefix from request uri", + "homepage": "https://github.com/lansoweb/basepath", + "time": "2016-08-27T20:56:32+00:00" + }, { "name": "nikic/fast-route", "version": "v1.2.0", @@ -343,12 +386,12 @@ "source": { "type": "git", "url": "https://github.com/Roave/SecurityAdvisories.git", - "reference": "a54d4cf91890993ee599c446e2eb3dba3f9eae32" + "reference": "402a514551804df5b4b2150f217e23a15408795a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Roave/SecurityAdvisories/zipball/a54d4cf91890993ee599c446e2eb3dba3f9eae32", - "reference": "a54d4cf91890993ee599c446e2eb3dba3f9eae32", + "url": "https://api.github.com/repos/Roave/SecurityAdvisories/zipball/402a514551804df5b4b2150f217e23a15408795a", + "reference": "402a514551804df5b4b2150f217e23a15408795a", "shasum": "" }, "conflict": { @@ -362,9 +405,10 @@ "codeigniter/framework": "<=3.0.6", "composer/composer": "<=1.0.0-alpha11", "contao-components/mediaelement": ">=2.14.2,<2.21.1", - "contao/core": ">=2,<3.5.31", + "contao/core": ">=2,<3.5.32", "contao/core-bundle": ">=4,<4.4.8", "contao/listing-bundle": ">=4,<4.4.8", + "contao/newsletter-bundle": ">=4,<4.1", "doctrine/annotations": ">=1,<1.2.7", "doctrine/cache": ">=1,<1.3.2|>=1.4,<1.4.2", "doctrine/common": ">=2,<2.4.3|>=2.5,<2.5.1", @@ -480,7 +524,7 @@ } ], "description": "Prevents installation of composer packages with known security vulnerabilities: no API, simply require it", - "time": "2018-01-13T18:31:46+00:00" + "time": "2018-01-18T10:00:53+00:00" }, { "name": "webimpress/composer-extra-dependency", @@ -3481,7 +3525,7 @@ "prefer-stable": false, "prefer-lowest": false, "platform": { - "php": "^7.0" + "php": "^7.1" }, "platform-dev": [] } diff --git a/config/autoload/los-basepath.global.php.dist b/config/autoload/los-basepath.global.php.dist new file mode 100644 index 0000000..f6070fa --- /dev/null +++ b/config/autoload/los-basepath.global.php.dist @@ -0,0 +1,21 @@ + '/cps', + + 'dependencies' => [ + 'factories' => [ + LosMiddleware\BasePath\BasePath::class => LosMiddleware\BasePath\BasePathFactory::class, + ], + ], + + 'middleware_pipeline' => [ + 'always' => [ + 'middleware' => [ + LosMiddleware\BasePath\BasePath::class + ], + ], + ], + +];