From 728b033ab22e76a21e99363a2a140203291ec784 Mon Sep 17 00:00:00 2001 From: George Steel Date: Wed, 12 Jan 2022 19:35:39 +0000 Subject: [PATCH 01/58] Adds a script to check out the current tree as a 2.99.x branch for CI runs so that composer will install cyclic incompatible dependencies. Signed-off-by: George Steel --- .laminas-ci/pre-install.sh | 7 +++++++ 1 file changed, 7 insertions(+) create mode 100755 .laminas-ci/pre-install.sh diff --git a/.laminas-ci/pre-install.sh b/.laminas-ci/pre-install.sh new file mode 100755 index 000000000..47bb37be8 --- /dev/null +++ b/.laminas-ci/pre-install.sh @@ -0,0 +1,7 @@ +#!/bin/bash + +# Temporary workaround for cyclic dependencies - can be removed once 3.0 has been released + +echo "Branch as 2.99.x in Pre-Install" + +git checkout -b 2.99.x From d55a6767a5f7163e7bb75f3bfd6f19c5a9b1d63f Mon Sep 17 00:00:00 2001 From: George Steel Date: Mon, 31 Jan 2022 20:36:44 +0000 Subject: [PATCH 02/58] Remove dependency on laminas-json - Removes deprecated JSON Expr finder compatibility in view helper and related deprecation errors - Removes composer dependency on `laminas-json` - Removes outdated documentation for Json Epr finder - Replaces usage of `Laminas\Json` with calls to native `json_encode` - Update psalm baseline Signed-off-by: George Steel --- composer.json | 1 - composer.lock | 63 +---------------------------------- docs/book/helpers/json.md | 26 --------------- psalm-baseline.xml | 14 -------- src/Helper/Json.php | 31 +++++++++-------- src/Model/JsonModel.php | 26 +++++++++++---- src/Renderer/JsonRenderer.php | 36 ++++++++++++++------ test/Helper/JsonTest.php | 28 ++++++---------- test/Model/JsonModelTest.php | 33 ++++++++++++++---- 9 files changed, 101 insertions(+), 157 deletions(-) diff --git a/composer.json b/composer.json index bdcbbaac8..ef9761530 100644 --- a/composer.json +++ b/composer.json @@ -22,7 +22,6 @@ "php": "^7.4 || ~8.0.0 || ~8.1.0", "ext-json": "*", "laminas/laminas-eventmanager": "^3.4", - "laminas/laminas-json": "^3.3", "laminas/laminas-stdlib": "^3.6" }, "require-dev": { diff --git a/composer.lock b/composer.lock index 90de23f62..741948c82 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "a003c15d0428178d28dd954a18766ec9", + "content-hash": "87da10378580603652a6399ab978b392", "packages": [ { "name": "laminas/laminas-eventmanager", @@ -72,67 +72,6 @@ ], "time": "2021-09-07T22:35:32+00:00" }, - { - "name": "laminas/laminas-json", - "version": "3.3.0", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-json.git", - "reference": "9a0ce9f330b7d11e70c4acb44d67e8c4f03f437f" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-json/zipball/9a0ce9f330b7d11e70c4acb44d67e8c4f03f437f", - "reference": "9a0ce9f330b7d11e70c4acb44d67e8c4f03f437f", - "shasum": "" - }, - "require": { - "php": "^7.3 || ~8.0.0 || ~8.1.0" - }, - "conflict": { - "zendframework/zend-json": "*" - }, - "require-dev": { - "laminas/laminas-coding-standard": "~2.2.1", - "laminas/laminas-stdlib": "^2.7.7 || ^3.1", - "phpunit/phpunit": "^9.3" - }, - "suggest": { - "laminas/laminas-json-server": "For implementing JSON-RPC servers", - "laminas/laminas-xml2json": "For converting XML documents to JSON" - }, - "type": "library", - "autoload": { - "psr-4": { - "Laminas\\Json\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "provides convenience methods for serializing native PHP to JSON and decoding JSON to native PHP", - "homepage": "https://laminas.dev", - "keywords": [ - "json", - "laminas" - ], - "support": { - "chat": "https://laminas.dev/chat", - "docs": "https://docs.laminas.dev/laminas-json/", - "forum": "https://discourse.laminas.dev", - "issues": "https://github.com/laminas/laminas-json/issues", - "rss": "https://github.com/laminas/laminas-json/releases.atom", - "source": "https://github.com/laminas/laminas-json" - }, - "funding": [ - { - "url": "https://funding.communitybridge.org/projects/laminas-project", - "type": "community_bridge" - } - ], - "time": "2021-09-02T18:02:31+00:00" - }, { "name": "laminas/laminas-stdlib", "version": "3.7.0", diff --git a/docs/book/helpers/json.md b/docs/book/helpers/json.md index 4a4056a02..655a9f788 100644 --- a/docs/book/helpers/json.md +++ b/docs/book/helpers/json.md @@ -19,29 +19,3 @@ determine how to handle the content. ```php json($this->data) ?> ``` - -> WARNING: **Deprecated** -> -> ### Enabling encoding using Laminas\Json\Expr -> -> **This feature of the Json view helper has been deprecated in version 2.16 and will be removed in version 3.0.** -> -> The JSON helper accepts an array of options that will be passed to `Laminas\Json\Json::encode()` and -> used internally to encode data. -> `Laminas\Json\Json::encode` allows the encoding of native JSON expressions using `Laminas\Json\Expr` -> objects. This option is disabled by default. To enable this option, pass a boolean `true` to the -> `enableJsonExprFinder` key of the options array: -> -> ```php -> json($this->data, ['enableJsonExprFinder' => true]) ?> -> `` -> -> The JSON helper accepts an array of options that will be passed to `Laminas\Json\Json::encode()` and -> used internally to encode data. -> `Laminas\Json\Json::encode` allows the encoding of native JSON expressions using `Laminas\Json\Expr` -> objects. This option is disabled by default. To enable this option, pass a boolean `true` to the -> `enableJsonExprFinder` key of the options array: -> -> ```php -> json($this->data, ['enableJsonExprFinder' => true]) ?> -> ``` diff --git a/psalm-baseline.xml b/psalm-baseline.xml index f7cb8e2e0..7e47f63f9 100644 --- a/psalm-baseline.xml +++ b/psalm-baseline.xml @@ -760,17 +760,6 @@ InlineScript - - - $response - - - null - - - $this->response instanceof Response - - null === $this->viewModelHelper @@ -1915,9 +1904,6 @@ - - void - $jsonpCallback diff --git a/src/Helper/Json.php b/src/Helper/Json.php index fa1c85b14..bc50abab5 100644 --- a/src/Helper/Json.php +++ b/src/Helper/Json.php @@ -5,37 +5,30 @@ namespace Laminas\View\Helper; use Laminas\Http\Response; -use Laminas\Json\Json as JsonFormatter; -use function trigger_error; +use function json_encode; -use const E_USER_DEPRECATED; +use const JSON_PRETTY_PRINT; +use const JSON_THROW_ON_ERROR; /** * Helper for simplifying JSON responses */ class Json extends AbstractHelper { - /** @var Response */ + /** @var Response|null */ protected $response; /** * Encode data as JSON and set response header * * @param mixed $data - * @param array $jsonOptions Options to pass to JsonFormatter::encode() - * @return string|void + * @param array{prettyPrint?: bool} $jsonOptions + * @return string */ public function __invoke($data, array $jsonOptions = []) { - if (isset($jsonOptions['enableJsonExprFinder']) && $jsonOptions['enableJsonExprFinder'] === true) { - trigger_error( - 'Json Expression functionality is deprecated and will be removed in laminas-view 3.0', - E_USER_DEPRECATED - ); - } - - $data = JsonFormatter::encode($data, null, $jsonOptions); + $data = json_encode($data, $this->optionsToFlags($jsonOptions)); if ($this->response instanceof Response) { $headers = $this->response->getHeaders(); @@ -45,6 +38,16 @@ public function __invoke($data, array $jsonOptions = []) return $data; } + /** @param array{prettyPrint?: bool} $options */ + private function optionsToFlags(array $options = []): int + { + $prettyPrint = $options['prettyPrint'] ?? false; + $flags = JSON_THROW_ON_ERROR; + $flags |= $prettyPrint ? 0 : JSON_PRETTY_PRINT; + + return $flags; + } + /** * Set the response object * diff --git a/src/Model/JsonModel.php b/src/Model/JsonModel.php index 186942003..2d4c9b761 100644 --- a/src/Model/JsonModel.php +++ b/src/Model/JsonModel.php @@ -4,10 +4,16 @@ namespace Laminas\View\Model; -use Laminas\Json\Json; +use JsonException; use Laminas\Stdlib\ArrayUtils; +use Laminas\View\Exception\DomainException; use Traversable; +use function json_encode; + +use const JSON_PRETTY_PRINT; +use const JSON_THROW_ON_ERROR; + class JsonModel extends ViewModel { /** @@ -56,13 +62,21 @@ public function serialize() $variables = ArrayUtils::iteratorToArray($variables); } - $options = [ - 'prettyPrint' => $this->getOption('prettyPrint'), - ]; + $options = (bool) $this->getOption('prettyPrint', false) ? JSON_PRETTY_PRINT : 0; if (null !== $this->jsonpCallback) { - return $this->jsonpCallback . '(' . Json::encode($variables, false, $options) . ');'; + return $this->jsonpCallback . '(' . $this->jsonEncode($variables, $options) . ');'; + } + return $this->jsonEncode($variables, $options); + } + + /** @param mixed $data */ + private function jsonEncode($data, int $options): string + { + try { + return json_encode($data, $options | JSON_THROW_ON_ERROR); + } catch (JsonException $e) { + throw new DomainException('Failed to encode Json', (int) $e->getCode(), $e); } - return Json::encode($variables, false, $options); } } diff --git a/src/Renderer/JsonRenderer.php b/src/Renderer/JsonRenderer.php index ecc9b115f..c296cd2bc 100644 --- a/src/Renderer/JsonRenderer.php +++ b/src/Renderer/JsonRenderer.php @@ -5,8 +5,8 @@ namespace Laminas\View\Renderer; use ArrayAccess; +use JsonException; use JsonSerializable; -use Laminas\Json\Json; use Laminas\Stdlib\ArrayUtils; use Laminas\View\Exception; use Laminas\View\Model\JsonModel; @@ -18,8 +18,11 @@ use function array_replace_recursive; use function get_object_vars; use function is_object; +use function json_encode; use function sprintf; +use const JSON_THROW_ON_ERROR; + /** * JSON renderer */ @@ -60,11 +63,13 @@ public function getEngine() * Set the resolver used to map a template name to a resource the renderer may consume. * * @todo Determine use case for resolvers when rendering JSON - * @return void + * @return self */ public function setResolver(Resolver $resolver) { $this->resolver = $resolver; + + return $this; } /** @@ -131,28 +136,27 @@ public function render($nameOrModel, $values = null) if ($nameOrModel instanceof JsonModel) { $children = $this->recurseModel($nameOrModel, false); $this->injectChildren($nameOrModel, $children); - $values = $nameOrModel->serialize(); + $output = $nameOrModel->serialize(); } else { - $values = $this->recurseModel($nameOrModel); - $values = Json::encode($values); + $output = $this->recurseModel($nameOrModel); + $output = $this->jsonEncode($output); } if ($this->hasJsonpCallback()) { - $values = $this->jsonpCallback . '(' . $values . ');'; + $output = $this->jsonpCallback . '(' . $output . ');'; } - return $values; + return $output; } // use case 2: $nameOrModel is populated, $values is not // Serialize $nameOrModel if (null === $values) { if (! is_object($nameOrModel) || $nameOrModel instanceof JsonSerializable) { - $return = Json::encode($nameOrModel); + $return = $this->jsonEncode($nameOrModel); } elseif ($nameOrModel instanceof Traversable) { - $nameOrModel = ArrayUtils::iteratorToArray($nameOrModel); - $return = Json::encode($nameOrModel); + $return = $this->jsonEncode(ArrayUtils::iteratorToArray($nameOrModel)); } else { - $return = Json::encode(get_object_vars($nameOrModel)); + $return = $this->jsonEncode(get_object_vars($nameOrModel)); } if ($this->hasJsonpCallback()) { @@ -237,4 +241,14 @@ protected function injectChildren(Model $model, array $children): void $model->setVariable($child, $value); } } + + /** @param mixed $data */ + private function jsonEncode($data): string + { + try { + return json_encode($data, JSON_THROW_ON_ERROR); + } catch (JsonException $e) { + throw new Exception\DomainException('Json encoding failed', (int) $e->getCode(), $e); + } + } } diff --git a/test/Helper/JsonTest.php b/test/Helper/JsonTest.php index b3308d9f2..f25ec8752 100644 --- a/test/Helper/JsonTest.php +++ b/test/Helper/JsonTest.php @@ -6,10 +6,13 @@ use Laminas\Http\Header\HeaderInterface; use Laminas\Http\Response; -use Laminas\Json\Json as JsonFormatter; use Laminas\View\Helper\Json as JsonHelper; use PHPUnit\Framework\TestCase; +use function json_encode; + +use const JSON_THROW_ON_ERROR; + /** * Test class for Laminas\View\Helper\Json * @@ -34,7 +37,7 @@ protected function setUp(): void $this->helper->setResponse($this->response); } - public function verifyJsonHeader(): void + private function verifyJsonHeader(): void { $headers = $this->response->getHeaders(); $this->assertTrue($headers->has('Content-Type')); @@ -51,20 +54,11 @@ public function testJsonHelperSetsResponseHeader(): void public function testJsonHelperReturnsJsonEncodedString(): void { - $data = $this->helper->__invoke('foobar'); - $this->assertIsString($data); - $this->assertEquals('foobar', JsonFormatter::decode($data)); - } - - public function testThatADeprecationErrorIsTriggeredWhenExpressionFinderOptionIsUsed(): void - { - $this->expectDeprecation(); - $this->helper->__invoke(['foo'], ['enableJsonExprFinder' => true]); - } - - public function testThatADeprecationErrorIsNotTriggeredWhenExpressionFinderOptionIsNotUsed(): void - { - $this->expectNotToPerformAssertions(); - $this->helper->__invoke(['foo'], ['enableJsonExprFinder' => 'anything other than true']); + $input = [ + 'dory' => 'blue', + 'nemo' => 'orange', + ]; + $expect = json_encode($input, JSON_THROW_ON_ERROR); + self::assertJsonStringEqualsJsonString($expect, ($this->helper)($input)); } } diff --git a/test/Model/JsonModelTest.php b/test/Model/JsonModelTest.php index 4319b799a..41b7e64ef 100644 --- a/test/Model/JsonModelTest.php +++ b/test/Model/JsonModelTest.php @@ -4,11 +4,17 @@ namespace LaminasTest\View\Model; -use Laminas\Json\Json; +use Laminas\View\Exception\DomainException; use Laminas\View\Model\JsonModel; use Laminas\View\Variables; use PHPUnit\Framework\TestCase; +use function json_encode; +use function sprintf; + +use const JSON_PRETTY_PRINT; +use const JSON_THROW_ON_ERROR; + class JsonModelTest extends TestCase { public function testAllowsEmptyConstructor(): void @@ -23,7 +29,7 @@ public function testCanSerializeVariablesToJson(): void $array = ['foo' => 'bar']; $model = new JsonModel($array); $this->assertEquals($array, $model->getVariables()); - $this->assertEquals(Json::encode($array), $model->serialize()); + $this->assertJsonStringEqualsJsonString(json_encode($array, JSON_THROW_ON_ERROR), $model->serialize()); } public function testCanSerializeWithJsonpCallback(): void @@ -31,12 +37,16 @@ public function testCanSerializeWithJsonpCallback(): void $array = ['foo' => 'bar']; $model = new JsonModel($array); $model->setJsonpCallback('callback'); - $this->assertEquals('callback(' . Json::encode($array) . ');', $model->serialize()); + $expect = sprintf( + 'callback(%s);', + json_encode($array, JSON_THROW_ON_ERROR) + ); + $this->assertEquals($expect, $model->serialize()); } public function testPrettyPrint(): void { - $array = [ + $array = [ 'simple' => 'simple test string', 'stringwithjsonchars' => '\"[1,2]', 'complex' => [ @@ -44,7 +54,18 @@ public function testPrettyPrint(): void 'far' => 'boo', ], ]; - $model = new JsonModel($array, ['prettyPrint' => true]); - $this->assertEquals(Json::encode($array, false, ['prettyPrint' => true]), $model->serialize()); + $model = new JsonModel($array, ['prettyPrint' => true]); + $expect = json_encode($array, JSON_THROW_ON_ERROR | JSON_PRETTY_PRINT); + $this->assertEquals($expect, $model->serialize()); + } + + public function testThatAnExceptionIsThrownIfItIsNotPossibleToEncodeThePayload(): void + { + $malformedUtf8 = [ + 'string' => "\x92", + ]; + $this->expectException(DomainException::class); + $this->expectExceptionMessage('Failed to encode Json'); + (new JsonModel($malformedUtf8))->serialize(); } } From 960d2d74e1a8e75a3ee8f69e6d5100f2b37f53c2 Mon Sep 17 00:00:00 2001 From: George Steel Date: Mon, 10 Jan 2022 19:58:30 +0000 Subject: [PATCH 03/58] Removes deprecated/obsolete Flash and QuickTime helpers Signed-off-by: George Steel --- docs/book/helpers/html-object.md | 4 +-- src/Helper/HtmlFlash.php | 33 ------------------- src/Helper/HtmlQuicktime.php | 54 ------------------------------- src/HelperPluginManager.php | 14 -------- test/Helper/HtmlFlashTest.php | 48 --------------------------- test/Helper/HtmlQuicktimeTest.php | 51 ----------------------------- 6 files changed, 1 insertion(+), 203 deletions(-) delete mode 100644 src/Helper/HtmlFlash.php delete mode 100644 src/Helper/HtmlQuicktime.php delete mode 100644 test/Helper/HtmlFlashTest.php delete mode 100644 test/Helper/HtmlQuicktimeTest.php diff --git a/docs/book/helpers/html-object.md b/docs/book/helpers/html-object.md index 276a4a076..ba1ecfa18 100644 --- a/docs/book/helpers/html-object.md +++ b/docs/book/helpers/html-object.md @@ -2,12 +2,10 @@ The [HTML `` element](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/object) is used for embedding external media in web pages. The object view helpers take care of embedding media with minimum effort. -There are four initial Object helpers: +There are two initial Object helpers: - `htmlObject()` Generates markup for embedding a custom Object. - `htmlPage()` Generates markup for embedding other (X)HTML pages. -- `htmlFlash()` Generates markup for embedding Flash files. _**Deprecated**_ -- `htmlQuicktime()` Generates markup for embedding QuickTime files. _**Deprecated**_ All of these helpers share a similar interface. For this reason, this documentation will only contain examples of two of these helpers. diff --git a/src/Helper/HtmlFlash.php b/src/Helper/HtmlFlash.php deleted file mode 100644 index 0354a28b6..000000000 --- a/src/Helper/HtmlFlash.php +++ /dev/null @@ -1,33 +0,0 @@ - $data, 'quality' => 'high'], $params); - - $htmlObject = $this->getView()->plugin('htmlObject'); - return $htmlObject($data, self::TYPE, $attribs, $params, $content); - } -} diff --git a/src/Helper/HtmlQuicktime.php b/src/Helper/HtmlQuicktime.php deleted file mode 100644 index b33aa8d2c..000000000 --- a/src/Helper/HtmlQuicktime.php +++ /dev/null @@ -1,54 +0,0 @@ - self::ATTRIB_CLASSID, 'codebase' => self::ATTRIB_CODEBASE]; - - /** - * Output a quicktime movie object tag - * - * @param string $data The quicktime file - * @param array $attribs Attribs for the object tag - * @param array $params Params for in the object tag - * @param string $content Alternative content - * @return string - */ - public function __invoke($data, array $attribs = [], array $params = [], $content = null) - { - // Attrs - $attribs = array_merge($this->attribs, $attribs); - - // Params - $params = array_merge(['src' => $data], $params); - - $htmlObject = $this->getView()->plugin('htmlObject'); - return $htmlObject($data, self::TYPE, $attribs, $params, $content); - } -} diff --git a/src/HelperPluginManager.php b/src/HelperPluginManager.php index 7de656e63..85df83923 100644 --- a/src/HelperPluginManager.php +++ b/src/HelperPluginManager.php @@ -94,9 +94,6 @@ class HelperPluginManager extends AbstractPluginManager 'htmlattributes' => Helper\HtmlAttributes::class, 'htmlAttributes' => Helper\HtmlAttributes::class, 'HtmlAttributes' => Helper\HtmlAttributes::class, - 'htmlflash' => Helper\HtmlFlash::class, - 'htmlFlash' => Helper\HtmlFlash::class, - 'HtmlFlash' => Helper\HtmlFlash::class, 'htmllist' => Helper\HtmlList::class, 'htmlList' => Helper\HtmlList::class, 'HtmlList' => Helper\HtmlList::class, @@ -106,9 +103,6 @@ class HelperPluginManager extends AbstractPluginManager 'htmlpage' => Helper\HtmlPage::class, 'htmlPage' => Helper\HtmlPage::class, 'HtmlPage' => Helper\HtmlPage::class, - 'htmlquicktime' => Helper\HtmlQuicktime::class, - 'htmlQuicktime' => Helper\HtmlQuicktime::class, - 'HtmlQuicktime' => Helper\HtmlQuicktime::class, 'htmltag' => Helper\HtmlTag::class, 'htmlTag' => Helper\HtmlTag::class, 'HtmlTag' => Helper\HtmlTag::class, @@ -173,11 +167,9 @@ class HelperPluginManager extends AbstractPluginManager \Zend\View\Helper\HeadScript::class => Helper\HeadScript::class, \Zend\View\Helper\HeadStyle::class => Helper\HeadStyle::class, \Zend\View\Helper\HeadTitle::class => Helper\HeadTitle::class, - \Zend\View\Helper\HtmlFlash::class => Helper\HtmlFlash::class, \Zend\View\Helper\HtmlList::class => Helper\HtmlList::class, \Zend\View\Helper\HtmlObject::class => Helper\HtmlObject::class, \Zend\View\Helper\HtmlPage::class => Helper\HtmlPage::class, - \Zend\View\Helper\HtmlQuicktime::class => Helper\HtmlQuicktime::class, \Zend\View\Helper\InlineScript::class => Helper\InlineScript::class, \Zend\View\Helper\Json::class => Helper\Json::class, \Zend\View\Helper\Layout::class => Helper\Layout::class, @@ -212,11 +204,9 @@ class HelperPluginManager extends AbstractPluginManager 'zendviewhelperheadscript' => Helper\HeadScript::class, 'zendviewhelperheadstyle' => Helper\HeadStyle::class, 'zendviewhelperheadtitle' => Helper\HeadTitle::class, - 'zendviewhelperhtmlflash' => Helper\HtmlFlash::class, 'zendviewhelperhtmllist' => Helper\HtmlList::class, 'zendviewhelperhtmlobject' => Helper\HtmlObject::class, 'zendviewhelperhtmlpage' => Helper\HtmlPage::class, - 'zendviewhelperhtmlquicktime' => Helper\HtmlQuicktime::class, 'zendviewhelperinlinescript' => Helper\InlineScript::class, 'zendviewhelperjson' => Helper\Json::class, 'zendviewhelperlayout' => Helper\Layout::class, @@ -265,11 +255,9 @@ class HelperPluginManager extends AbstractPluginManager Helper\HeadScript::class => InvokableFactory::class, Helper\HeadStyle::class => InvokableFactory::class, Helper\HeadTitle::class => InvokableFactory::class, - Helper\HtmlFlash::class => InvokableFactory::class, Helper\HtmlList::class => InvokableFactory::class, Helper\HtmlObject::class => InvokableFactory::class, Helper\HtmlPage::class => InvokableFactory::class, - Helper\HtmlQuicktime::class => InvokableFactory::class, Helper\InlineScript::class => InvokableFactory::class, Helper\Json::class => InvokableFactory::class, Helper\Layout::class => InvokableFactory::class, @@ -304,11 +292,9 @@ class HelperPluginManager extends AbstractPluginManager 'laminasviewhelperheadscript' => InvokableFactory::class, 'laminasviewhelperheadstyle' => InvokableFactory::class, 'laminasviewhelperheadtitle' => InvokableFactory::class, - 'laminasviewhelperhtmlflash' => InvokableFactory::class, 'laminasviewhelperhtmllist' => InvokableFactory::class, 'laminasviewhelperhtmlobject' => InvokableFactory::class, 'laminasviewhelperhtmlpage' => InvokableFactory::class, - 'laminasviewhelperhtmlquicktime' => InvokableFactory::class, 'laminasviewhelperinlinescript' => InvokableFactory::class, 'laminasviewhelperjson' => InvokableFactory::class, 'laminasviewhelperlayout' => InvokableFactory::class, diff --git a/test/Helper/HtmlFlashTest.php b/test/Helper/HtmlFlashTest.php deleted file mode 100644 index 5c931f563..000000000 --- a/test/Helper/HtmlFlashTest.php +++ /dev/null @@ -1,48 +0,0 @@ -view = new View(); - /** @psalm-suppress DeprecatedClass */ - $this->helper = new HtmlFlash(); - $this->helper->setView($this->view); - } - - public function testMakeHtmlFlash(): void - { - $htmlFlash = $this->helper->__invoke('/path/to/flash.swf'); - - // @codingStandardsIgnoreStart - $objectStartElement = ''; - // @codingStandardsIgnoreEnd - - $this->assertStringContainsString($objectStartElement, $htmlFlash); - $this->assertStringContainsString('', $htmlFlash); - } -} diff --git a/test/Helper/HtmlQuicktimeTest.php b/test/Helper/HtmlQuicktimeTest.php deleted file mode 100644 index b3d5136ac..000000000 --- a/test/Helper/HtmlQuicktimeTest.php +++ /dev/null @@ -1,51 +0,0 @@ -view = new View(); - /** @psalm-suppress DeprecatedClass */ - $this->helper = new HtmlQuicktime(); - $this->helper->setView($this->view); - } - - public function testMakeHtmlQuicktime(): void - { - $htmlQuicktime = $this->helper->__invoke('/path/to/quicktime.mov'); - - $objectStartElement = ''; - - $this->assertStringContainsString($objectStartElement, $htmlQuicktime); - $this->assertStringContainsString('', $htmlQuicktime); - } -} From 18f4cf6d5d86f6b29be117b39380a7d5393e6a66 Mon Sep 17 00:00:00 2001 From: George Steel Date: Mon, 31 Jan 2022 23:10:49 +0000 Subject: [PATCH 04/58] Remove legacy Zend compatibility - Removes hard-coded, zend-related aliases from the various plugin managers - Removes code that searches the container for Zend\Authentication in the Identity helper factory - Cleans up the test for the identity helper factory to use regular PHP Unit mocks and also compatibility with ServiceManager 2.x which is long gone. - Updates psalm baseline Signed-off-by: George Steel --- psalm-baseline.xml | 85 +-------------------- src/Helper/Navigation/PluginManager.php | 12 --- src/Helper/Service/IdentityFactory.php | 29 +++---- src/HelperPluginManager.php | 78 ------------------- test/Helper/Service/IdentityFactoryTest.php | 84 ++++++++------------ 5 files changed, 49 insertions(+), 239 deletions(-) diff --git a/psalm-baseline.xml b/psalm-baseline.xml index 7e47f63f9..724fe8da4 100644 --- a/psalm-baseline.xml +++ b/psalm-baseline.xml @@ -24,7 +24,7 @@ - + $closingBracket $closingBracket $closingBracket @@ -631,26 +631,6 @@ translate - - - $htmlObject - - - $htmlObject($data, self::TYPE, $attribs, $params, $content) - - - string - - - $htmlObject($data, self::TYPE, $attribs, $params, $content) - - - plugin - - - plugin - - array @@ -705,26 +685,6 @@ plugin - - - $htmlObject - - - $htmlObject($data, self::TYPE, $attribs, $params, $content) - - - string - - - $htmlObject($data, self::TYPE, $attribs, $params, $content) - - - plugin - - - plugin - - $value @@ -1675,16 +1635,6 @@ IdentityFactory - - null|AuthenticationServiceInterface - - - $container->get(AuthenticationService::class) - $container->get(\Zend\Authentication\AuthenticationService::class) - - - $cName - @@ -2842,11 +2792,6 @@ renderTitle - - - $this->view - - false @@ -3406,34 +3351,6 @@ 1337 - - - $this->getContainerForFactory() - $this->getContainerForFactory() - $this->getContainerForFactory() - - - $this->prophesize(ServiceManager::class) - - - ContainerInterface - - - willReturn - willReturn - willReturn - willReturn - willReturn - willReturn - willReturn - willReturn - willReturn - willReturn - - - $this->services->reveal() - - Bar diff --git a/src/Helper/Navigation/PluginManager.php b/src/Helper/Navigation/PluginManager.php index 7ed5cf102..25acfa0d1 100644 --- a/src/Helper/Navigation/PluginManager.php +++ b/src/Helper/Navigation/PluginManager.php @@ -33,18 +33,6 @@ class PluginManager extends HelperPluginManager 'links' => Links::class, 'menu' => Menu::class, 'sitemap' => Sitemap::class, - - // Legacy Zend Framework aliases - \Zend\View\Helper\Navigation\Breadcrumbs::class => Breadcrumbs::class, - \Zend\View\Helper\Navigation\Links::class => Links::class, // phpcs:ignore - \Zend\View\Helper\Navigation\Menu::class => Menu::class, - \Zend\View\Helper\Navigation\Sitemap::class => Sitemap::class, - - // v2 normalized FQCNs - 'zendviewhelpernavigationbreadcrumbs' => Breadcrumbs::class, - 'zendviewhelpernavigationlinks' => Links::class, - 'zendviewhelpernavigationmenu' => Menu::class, - 'zendviewhelpernavigationsitemap' => Sitemap::class, ]; /** diff --git a/src/Helper/Service/IdentityFactory.php b/src/Helper/Service/IdentityFactory.php index 9e0e8c296..e06be149a 100644 --- a/src/Helper/Service/IdentityFactory.php +++ b/src/Helper/Service/IdentityFactory.php @@ -11,14 +11,16 @@ use Laminas\ServiceManager\ServiceLocatorInterface; use Laminas\View\Helper\Identity; +use function assert; + class IdentityFactory implements FactoryInterface { /** - * @param string $name + * @param string|null $name * @param null|array $options * @return Identity */ - public function __invoke(ContainerInterface $container, $name, ?array $options = null) + public function __invoke(ContainerInterface $container, $name = null, ?array $options = null) { $helper = new Identity(); @@ -41,23 +43,22 @@ public function createService(ServiceLocatorInterface $serviceLocator, $rName = return $this($serviceLocator, $cName); } - /** - * @return null|AuthenticationServiceInterface - */ - private function discoverAuthenticationService(ContainerInterface $container) + private function discoverAuthenticationService(ContainerInterface $container): ?AuthenticationServiceInterface { if ($container->has(AuthenticationService::class)) { - return $container->get(AuthenticationService::class); + $service1 = $container->get(AuthenticationService::class); + assert($service1 instanceof AuthenticationServiceInterface); + + return $service1; } - if ($container->has(\Zend\Authentication\AuthenticationService::class)) { - return $container->get(\Zend\Authentication\AuthenticationService::class); + if ($container->has(AuthenticationServiceInterface::class)) { + $service2 = $container->get(AuthenticationServiceInterface::class); + assert($service2 instanceof AuthenticationServiceInterface); + + return $service2; } - return $container->has(AuthenticationServiceInterface::class) - ? $container->get(AuthenticationServiceInterface::class) - : ($container->has(\Zend\Authentication\AuthenticationServiceInterface::class) - ? $container->get(\Zend\Authentication\AuthenticationServiceInterface::class) - : null); + return null; } } diff --git a/src/HelperPluginManager.php b/src/HelperPluginManager.php index 85df83923..775d1e560 100644 --- a/src/HelperPluginManager.php +++ b/src/HelperPluginManager.php @@ -141,84 +141,6 @@ class HelperPluginManager extends AbstractPluginManager 'viewmodel' => Helper\ViewModel::class, 'viewModel' => Helper\ViewModel::class, 'ViewModel' => Helper\ViewModel::class, - - /** - * Legacy Zend Framework aliases - * - * @psalm-suppress DeprecatedClass - * @codingStandardsIgnoreStart - **/ - \Zend\View\Helper\Asset::class => Helper\Asset::class, - \Zend\View\Helper\FlashMessenger::class => Helper\FlashMessenger::class, - \Zend\View\Helper\Identity::class => Helper\Identity::class, - \Zend\View\Helper\BasePath::class => Helper\BasePath::class, - \Zend\View\Helper\Cycle::class => Helper\Cycle::class, - \Zend\View\Helper\DeclareVars::class => Helper\DeclareVars::class, - \Zend\View\Helper\Doctype::class => Helper\Doctype::class, - \Zend\View\Helper\EscapeHtml::class => Helper\EscapeHtml::class, - \Zend\View\Helper\EscapeHtmlAttr::class => Helper\EscapeHtmlAttr::class, - \Zend\View\Helper\EscapeJs::class => Helper\EscapeJs::class, - \Zend\View\Helper\EscapeCss::class => Helper\EscapeCss::class, - \Zend\View\Helper\EscapeUrl::class => Helper\EscapeUrl::class, - \Zend\View\Helper\Gravatar::class => Helper\Gravatar::class, - \Zend\View\Helper\HtmlTag::class => Helper\HtmlTag::class, - \Zend\View\Helper\HeadLink::class => Helper\HeadLink::class, - \Zend\View\Helper\HeadMeta::class => Helper\HeadMeta::class, - \Zend\View\Helper\HeadScript::class => Helper\HeadScript::class, - \Zend\View\Helper\HeadStyle::class => Helper\HeadStyle::class, - \Zend\View\Helper\HeadTitle::class => Helper\HeadTitle::class, - \Zend\View\Helper\HtmlList::class => Helper\HtmlList::class, - \Zend\View\Helper\HtmlObject::class => Helper\HtmlObject::class, - \Zend\View\Helper\HtmlPage::class => Helper\HtmlPage::class, - \Zend\View\Helper\InlineScript::class => Helper\InlineScript::class, - \Zend\View\Helper\Json::class => Helper\Json::class, - \Zend\View\Helper\Layout::class => Helper\Layout::class, - \Zend\View\Helper\PaginationControl::class => Helper\PaginationControl::class, - \Zend\View\Helper\PartialLoop::class => Helper\PartialLoop::class, - \Zend\View\Helper\Partial::class => Helper\Partial::class, - \Zend\View\Helper\Placeholder::class => Helper\Placeholder::class, - \Zend\View\Helper\RenderChildModel::class => Helper\RenderChildModel::class, - \Zend\View\Helper\RenderToPlaceholder::class => Helper\RenderToPlaceholder::class, - \Zend\View\Helper\ServerUrl::class => Helper\ServerUrl::class, - \Zend\View\Helper\Url::class => Helper\Url::class, - \Zend\View\Helper\ViewModel::class => Helper\ViewModel::class, - // @codingStandardsIgnoreEnd - - // v2 normalized FQCNs - 'zendviewhelperasset' => Helper\Asset::class, - 'zendviewhelperflashmessenger' => Helper\FlashMessenger::class, - 'zendviewhelperidentity' => Helper\Identity::class, - 'zendviewhelperbasepath' => Helper\BasePath::class, - 'zendviewhelpercycle' => Helper\Cycle::class, - 'zendviewhelperdeclarevars' => Helper\DeclareVars::class, - 'zendviewhelperdoctype' => Helper\Doctype::class, - 'zendviewhelperescapehtml' => Helper\EscapeHtml::class, - 'zendviewhelperescapehtmlattr' => Helper\EscapeHtmlAttr::class, - 'zendviewhelperescapejs' => Helper\EscapeJs::class, - 'zendviewhelperescapecss' => Helper\EscapeCss::class, - 'zendviewhelperescapeurl' => Helper\EscapeUrl::class, - 'zendviewhelpergravatar' => Helper\Gravatar::class, - 'zendviewhelperhtmltag' => Helper\HtmlTag::class, - 'zendviewhelperheadlink' => Helper\HeadLink::class, - 'zendviewhelperheadmeta' => Helper\HeadMeta::class, - 'zendviewhelperheadscript' => Helper\HeadScript::class, - 'zendviewhelperheadstyle' => Helper\HeadStyle::class, - 'zendviewhelperheadtitle' => Helper\HeadTitle::class, - 'zendviewhelperhtmllist' => Helper\HtmlList::class, - 'zendviewhelperhtmlobject' => Helper\HtmlObject::class, - 'zendviewhelperhtmlpage' => Helper\HtmlPage::class, - 'zendviewhelperinlinescript' => Helper\InlineScript::class, - 'zendviewhelperjson' => Helper\Json::class, - 'zendviewhelperlayout' => Helper\Layout::class, - 'zendviewhelperpaginationcontrol' => Helper\PaginationControl::class, - 'zendviewhelperpartialloop' => Helper\PartialLoop::class, - 'zendviewhelperpartial' => Helper\Partial::class, - 'zendviewhelperplaceholder' => Helper\Placeholder::class, - 'zendviewhelperrenderchildmodel' => Helper\RenderChildModel::class, - 'zendviewhelperrendertoplaceholder' => Helper\RenderToPlaceholder::class, - 'zendviewhelperserverurl' => Helper\ServerUrl::class, - 'zendviewhelperurl' => Helper\Url::class, - 'zendviewhelperviewmodel' => Helper\ViewModel::class, ]; /** diff --git a/test/Helper/Service/IdentityFactoryTest.php b/test/Helper/Service/IdentityFactoryTest.php index 89fccc0ea..ba3544dd0 100644 --- a/test/Helper/Service/IdentityFactoryTest.php +++ b/test/Helper/Service/IdentityFactoryTest.php @@ -4,57 +4,36 @@ namespace LaminasTest\View\Helper\Service; +use Interop\Container\ContainerInterface; use Laminas\Authentication\AuthenticationService; use Laminas\Authentication\AuthenticationServiceInterface; -use Laminas\ServiceManager\ServiceManager; use Laminas\View\Helper\Identity; use Laminas\View\Helper\Service\IdentityFactory; -use Laminas\View\HelperPluginManager; +use PHPUnit\Framework\MockObject\MockObject; use PHPUnit\Framework\TestCase; -use Prophecy\PhpUnit\ProphecyTrait; -use Prophecy\Prophecy\ObjectProphecy; -use Psr\Container\ContainerInterface; - -use function method_exists; class IdentityFactoryTest extends TestCase { - use ProphecyTrait; - - /** @var ObjectProphecy&ServiceManager&ContainerInterface */ - private $services; - /** @var HelperPluginManager&ContainerInterface */ - private $helpers; + /** @var MockObject&ContainerInterface */ + private ContainerInterface $services; protected function setUp(): void { - $this->services = $this->prophesize(ServiceManager::class); - $this->helpers = new HelperPluginManager($this->services->reveal()); - } - - public function getContainerForFactory(): ContainerInterface - { - if (method_exists($this->helpers, 'configure')) { - return $this->services->reveal(); - } - return $this->helpers; + $this->services = $this->createMock(ContainerInterface::class); } public function testFactoryReturnsEmptyIdentityIfNoAuthenticationServicePresent(): void { - $this->services->has(AuthenticationService::class)->willReturn(false); - - $this->services->has(\Zend\Authentication\AuthenticationService::class)->willReturn(false); - $this->services->get(AuthenticationService::class)->shouldNotBeCalled(); - $this->services->get(\Zend\Authentication\AuthenticationService::class)->shouldNotBeCalled(); - $this->services->has(AuthenticationServiceInterface::class)->willReturn(false); - $this->services->has(\Zend\Authentication\AuthenticationServiceInterface::class)->willReturn(false); - $this->services->get(AuthenticationServiceInterface::class)->shouldNotBeCalled(); - $this->services->get(\Zend\Authentication\AuthenticationServiceInterface::class)->shouldNotBeCalled(); + $this->services->expects(self::exactly(2)) + ->method('has') + ->withConsecutive( + [AuthenticationService::class], + [AuthenticationServiceInterface::class] + )->willReturn(false); $factory = new IdentityFactory(); - $plugin = $factory($this->getContainerForFactory(), Identity::class); + $plugin = $factory($this->services); $this->assertInstanceOf(Identity::class, $plugin); $this->assertNull($plugin->getAuthenticationService()); @@ -62,40 +41,43 @@ public function testFactoryReturnsEmptyIdentityIfNoAuthenticationServicePresent( public function testFactoryReturnsIdentityWithConfiguredAuthenticationServiceWhenPresent(): void { - $authentication = $this->prophesize(AuthenticationService::class); + $authService = $this->createMock(AuthenticationServiceInterface::class); + $this->services->expects(self::once()) + ->method('has') + ->with(AuthenticationService::class) + ->willReturn(true); - $this->services->has(AuthenticationService::class)->willReturn(true); - $this->services->get(AuthenticationService::class)->will([$authentication, 'reveal']); - $this->services->has(AuthenticationServiceInterface::class)->willReturn(false); - $this->services->has(\Zend\Authentication\AuthenticationServiceInterface::class)->willReturn(false); - $this->services->get(AuthenticationServiceInterface::class)->shouldNotBeCalled(); - $this->services->get(\Zend\Authentication\AuthenticationServiceInterface::class)->shouldNotBeCalled(); + $this->services->expects(self::once()) + ->method('get') + ->with(AuthenticationService::class) + ->willReturn($authService); $factory = new IdentityFactory(); - $plugin = $factory($this->getContainerForFactory(), Identity::class); + $plugin = $factory($this->services); $this->assertInstanceOf(Identity::class, $plugin); - $this->assertSame($authentication->reveal(), $plugin->getAuthenticationService()); + $this->assertSame($authService, $plugin->getAuthenticationService()); } public function testFactoryReturnsIdentityWithConfiguredAuthenticationServiceInterfaceWhenPresent(): void { - $authentication = $this->prophesize(AuthenticationServiceInterface::class); + $authService = $this->createMock(AuthenticationServiceInterface::class); - $this->services->has(AuthenticationService::class)->willReturn(false); + $this->services->expects(self::exactly(2)) + ->method('has') + ->willReturnOnConsecutiveCalls(false, true); - $this->services->has(\Zend\Authentication\AuthenticationService::class)->willReturn(false); - $this->services->get(AuthenticationService::class)->shouldNotBeCalled(); - $this->services->get(\Zend\Authentication\AuthenticationService::class)->shouldNotBeCalled(); - $this->services->has(AuthenticationServiceInterface::class)->willReturn(true); - $this->services->get(AuthenticationServiceInterface::class)->will([$authentication, 'reveal']); + $this->services->expects(self::once()) + ->method('get') + ->with(AuthenticationServiceInterface::class) + ->willReturn($authService); $factory = new IdentityFactory(); - $plugin = $factory($this->getContainerForFactory(), Identity::class); + $plugin = $factory($this->services); $this->assertInstanceOf(Identity::class, $plugin); - $this->assertSame($authentication->reveal(), $plugin->getAuthenticationService()); + $this->assertSame($authService, $plugin->getAuthenticationService()); } } From 90a47947d9a50f854c6614e14ca416676a32cff0 Mon Sep 17 00:00:00 2001 From: George Steel Date: Mon, 31 Jan 2022 23:34:21 +0000 Subject: [PATCH 05/58] Remove Stream Wrapper Functionality - Updates the path stack template resolver removing deprecated methods related to stream wrapper - Removes the Stream wrapper class - Updates psalm baseline Signed-off-by: George Steel --- psalm-baseline.xml | 32 +--- src/Resolver/TemplatePathStack.php | 61 +------ src/Stream.php | 204 ------------------------ test/Resolver/TemplatePathStackTest.php | 46 +----- 4 files changed, 5 insertions(+), 338 deletions(-) delete mode 100644 src/Stream.php diff --git a/psalm-baseline.xml b/psalm-baseline.xml index 724fe8da4..8b2de156b 100644 --- a/psalm-baseline.xml +++ b/psalm-baseline.xml @@ -2049,7 +2049,7 @@ false false - + $value $value $value @@ -2063,7 +2063,7 @@ $this->paths - + (bool) $flag (bool) $flag (string) $defaultSuffix @@ -2120,34 +2120,6 @@ plugin - - - $data - $stat - - - $mode - $offset - $opened_path - $options - $whence - - - $this->pos - $this->pos - $this->pos - - - $offset - $offset - $offset - - - break; - break; - break; - - 'ArrayIterator' diff --git a/src/Resolver/TemplatePathStack.php b/src/Resolver/TemplatePathStack.php index 8781afa1a..16fa9c2ac 100644 --- a/src/Resolver/TemplatePathStack.php +++ b/src/Resolver/TemplatePathStack.php @@ -7,7 +7,6 @@ use Laminas\Stdlib\SplStack; use Laminas\View\Exception; use Laminas\View\Renderer\RendererInterface as Renderer; -use Laminas\View\Stream; use SplFileInfo; use Traversable; @@ -15,8 +14,6 @@ use function file_exists; use function get_class; use function gettype; -use function in_array; -use function ini_get; use function is_array; use function is_object; use function is_string; @@ -25,8 +22,6 @@ use function preg_match; use function rtrim; use function sprintf; -use function stream_get_wrappers; -use function stream_wrapper_register; use function strpos; use function strtolower; @@ -69,15 +64,6 @@ class TemplatePathStack implements ResolverInterface */ protected $lfiProtectionOn = true; - /**@+ - * Flags used to determine if a stream wrapper should be used for enabling short tags - */ - - /** @var bool */ - protected $useViewStream = false; - /** @var bool */ - protected $useStreamWrapper = false; - /**@-*/ /** @@ -87,14 +73,6 @@ class TemplatePathStack implements ResolverInterface */ public function __construct($options = null) { - $this->useViewStream = (bool) ini_get('short_open_tag'); - if ($this->useViewStream) { - if (! in_array('laminas.view', stream_get_wrappers())) { - /** @psalm-suppress DeprecatedClass */ - stream_wrapper_register('laminas.view', Stream::class); - } - } - /** @psalm-var PathStack $paths */ $paths = new SplStack(); $this->paths = $paths; @@ -128,10 +106,6 @@ public function setOptions($options) case 'script_paths': $this->addPaths($value); break; - case 'use_stream_wrapper': - /** @psalm-suppress DeprecatedMethod */ - $this->setUseStreamWrapper($value); - break; case 'default_suffix': $this->setDefaultSuffix($value); break; @@ -283,35 +257,6 @@ public function isLfiProtectionOn() return $this->lfiProtectionOn; } - /** - * Set flag indicating if stream wrapper should be used if short_open_tag is off - * - * @deprecated will be removed in version 3 - * - * @param bool $flag - * @return TemplatePathStack - */ - public function setUseStreamWrapper($flag) - { - $this->useStreamWrapper = (bool) $flag; - return $this; - } - - /** - * Should the stream wrapper be used if short_open_tag is off? - * - * Returns true if the use_stream_wrapper flag is set, and if short_open_tag - * is disabled. - * - * @deprecated will be removed in version 3 - * - * @return bool - */ - public function useStreamWrapper() - { - return $this->useViewStream && $this->useStreamWrapper; - } - /** * Retrieve the filesystem path to a view script * @@ -351,11 +296,7 @@ public function resolve($name, ?Renderer $renderer = null) break; } } - /** @psalm-suppress DeprecatedMethod */ - if ($this->useStreamWrapper()) { - // If using a stream wrapper, prepend the spec to the path - $filePath = 'laminas.view://' . $filePath; - } + return $filePath; } } diff --git a/src/Stream.php b/src/Stream.php deleted file mode 100644 index b0829c232..000000000 --- a/src/Stream.php +++ /dev/null @@ -1,204 +0,0 @@ - and ) should be used - */ -class Stream -{ - /** - * Current stream position. - * - * @var int - */ - protected $pos = 0; - - /** - * Data for streaming. - * - * @var string - */ - protected $data; - - /** - * Stream stats. - * - * @var array - */ - protected $stat; - - /** - * Opens the script file and converts markup. - * - * @param string $path - * @param $mode - * @param $options - * @param $opened_path - * @return bool - */ - // @codingStandardsIgnoreStart - public function stream_open($path, $mode, $options, &$opened_path) - { - // @codingStandardsIgnoreEnd - // get the view script source - $path = str_replace('laminas.view://', '', $path); - $this->data = file_get_contents($path); - - /** - * If reading the file failed, update our local stat store - * to reflect the real stat of the file, then return on failure - */ - if ($this->data === false) { - $this->stat = stat($path); - return false; - } - - /** - * Convert to long-form and to - */ - $this->data = preg_replace('/\<\?\=/', "data); - $this->data = preg_replace('/<\?(?!xml|php)/s', 'data); - - /** - * file_get_contents() won't update PHP's stat cache, so we grab a stat - * of the file to prevent additional reads should the script be - * requested again, which will make include() happy. - */ - $this->stat = stat($path); - - return true; - } - - /** - * Included so that __FILE__ returns the appropriate info - * - * @return array - */ - // @codingStandardsIgnoreStart - public function url_stat() - { - // @codingStandardsIgnoreEnd - return $this->stat; - } - - /** - * Reads from the stream. - * - * @param int $count - * @return string - */ - // @codingStandardsIgnoreStart - public function stream_read($count) - { - // @codingStandardsIgnoreEnd - $ret = substr($this->data, $this->pos, $count); - $this->pos += strlen($ret); - return $ret; - } - - /** - * Tells the current position in the stream. - * - * @return int - */ - // @codingStandardsIgnoreStart - public function stream_tell() - { - // @codingStandardsIgnoreEnd - return $this->pos; - } - - /** - * Tells if we are at the end of the stream. - * - * @return bool - */ - // @codingStandardsIgnoreStart - public function stream_eof() - { - // @codingStandardsIgnoreEnd - return $this->pos >= strlen($this->data); - } - - /** - * Stream statistics. - * - * @return array - */ - // @codingStandardsIgnoreStart - public function stream_stat() - { - // @codingStandardsIgnoreEnd - return $this->stat; - } - - /** - * Seek to a specific point in the stream. - * - * @param $offset - * @param $whence - * @return bool - */ - // @codingStandardsIgnoreStart - public function stream_seek($offset, $whence) - { - // @codingStandardsIgnoreEnd - switch ($whence) { - case SEEK_SET: - if ($offset < strlen($this->data) && $offset >= 0) { - $this->pos = $offset; - return true; - } else { - return false; - } - break; - - case SEEK_CUR: - if ($offset >= 0) { - $this->pos += $offset; - return true; - } else { - return false; - } - break; - - case SEEK_END: - if (strlen($this->data) + $offset >= 0) { - $this->pos = strlen($this->data) + $offset; - return true; - } else { - return false; - } - break; - - default: - return false; - } - } -} diff --git a/test/Resolver/TemplatePathStackTest.php b/test/Resolver/TemplatePathStackTest.php index d67ca1a1a..76fdd2a3c 100644 --- a/test/Resolver/TemplatePathStackTest.php +++ b/test/Resolver/TemplatePathStackTest.php @@ -12,7 +12,6 @@ use function array_reverse; use function array_unshift; -use function ini_get; use function realpath; use const DIRECTORY_SEPARATOR; @@ -107,24 +106,6 @@ public function testMayDisableLfiProtection(): void $this->assertFalse($this->stack->isLfiProtectionOn()); } - public function testStreamWrapperDisabledByDefault(): void - { - /** @psalm-suppress DeprecatedMethod */ - $this->assertFalse($this->stack->useStreamWrapper()); - } - - public function testMayEnableStreamWrapper(): void - { - $flag = (bool) ini_get('short_open_tag'); - if (! $flag) { - $this->markTestSkipped('Short tags are disabled; cannot test'); - } - /** @psalm-suppress DeprecatedMethod */ - $this->stack->setUseStreamWrapper(true); - /** @psalm-suppress DeprecatedMethod */ - $this->assertTrue($this->stack->useStreamWrapper()); - } - public function testDoesNotAllowParentDirectoryTraversalByDefault(): void { $this->stack->addPath($this->baseDir . '/_templates'); @@ -164,20 +145,6 @@ public function testReturnsFullPathNameWhenAbleToResolveScriptPath(): void $this->assertEquals($expected, $test); } - public function testReturnsPathWithStreamProtocolWhenStreamWrapperEnabled(): void - { - $flag = (bool) ini_get('short_open_tag'); - if (! $flag) { - $this->markTestSkipped('Short tags are disabled; cannot test'); - } - /** @psalm-suppress DeprecatedMethod */ - $this->stack->setUseStreamWrapper(true) - ->addPath($this->baseDir . '/_templates'); - $expected = 'laminas.view://' . realpath($this->baseDir . '/_templates/test.phtml'); - $test = $this->stack->resolve('test.phtml'); - $this->assertEquals($expected, $test); - } - /** * @psalm-return array */ @@ -209,9 +176,8 @@ public function testSettingOptionsWithInvalidArgumentRaisesException($options): public function validOptions(): array { $options = [ - 'lfi_protection' => false, - 'use_stream_wrapper' => true, - 'default_suffix' => 'php', + 'lfi_protection' => false, + 'default_suffix' => 'php', ]; return [ [$options], @@ -229,10 +195,6 @@ public function testAllowsSettingOptions($options): void $this->stack->setOptions($options); $this->assertFalse($this->stack->isLfiProtectionOn()); - $expected = (bool) ini_get('short_open_tag'); - /** @psalm-suppress DeprecatedMethod */ - $this->assertSame($expected, $this->stack->useStreamWrapper()); - $this->assertSame($options['default_suffix'], $this->stack->getDefaultSuffix()); $this->assertEquals(array_reverse($this->paths), $this->stack->getPaths()->toArray()); @@ -248,10 +210,6 @@ public function testAllowsPassingOptionsToConstructor($options): void $stack = new TemplatePathStack($options); $this->assertFalse($stack->isLfiProtectionOn()); - $expected = (bool) ini_get('short_open_tag'); - /** @psalm-suppress DeprecatedMethod */ - $this->assertSame($expected, $stack->useStreamWrapper()); - $this->assertEquals(array_reverse($this->paths), $stack->getPaths()->toArray()); } From 6f5257739c19169cbd26015ee5a113c5cb63c6be Mon Sep 17 00:00:00 2001 From: Abdul Malik Ikhsan Date: Sat, 9 May 2020 15:18:20 +0700 Subject: [PATCH 06/58] remove E_USER_DEPRECATED deprecated methods Signed-off-by: Abdul Malik Ikhsan --- src/Helper/Gravatar.php | 43 ----------------------------- src/Helper/Placeholder/Registry.php | 28 ------------------- 2 files changed, 71 deletions(-) diff --git a/src/Helper/Gravatar.php b/src/Helper/Gravatar.php index 65a42ac36..8776a2b2c 100644 --- a/src/Helper/Gravatar.php +++ b/src/Helper/Gravatar.php @@ -196,26 +196,6 @@ public function setAttributes(array $attributes) return $this; } - /** - * Set attribs for image tag - * - * @deprecated Please use Laminas\View\Helper\Gravatar::setAttributes - * - * @param array $attribs - * @return Gravatar - */ - public function setAttribs(array $attribs) - { - trigger_error(sprintf( - '%s is deprecated; please use %s::setAttributes', - __METHOD__, - self::class - ), E_USER_DEPRECATED); - - $this->setAttributes($attribs); - return $this; - } - /** * Get attributes of image * @@ -231,29 +211,6 @@ public function getAttributes() return $this->attributes; } - /** - * Get attribs of image - * - * Warning! - * If you set src attrib, you get it, but this value will be overwritten in - * protected method setSrcAttribForImg(). And finally your get other src - * value! - * - * @deprecated Please use Laminas\View\Helper\Gravatar::getAttributes - * - * @return array - */ - public function getAttribs() - { - trigger_error(sprintf( - '%s is deprecated; please use %s::getAttributes', - __METHOD__, - self::class - ), E_USER_DEPRECATED); - - return $this->getAttributes(); - } - /** * Set default img * diff --git a/src/Helper/Placeholder/Registry.php b/src/Helper/Placeholder/Registry.php index 5de7c967c..303216f3f 100644 --- a/src/Helper/Placeholder/Registry.php +++ b/src/Helper/Placeholder/Registry.php @@ -42,34 +42,6 @@ class Registry */ protected $items = []; - /** - * Retrieve or create registry instance - * - * @return Registry - */ - public static function getRegistry() - { - trigger_error('Placeholder view helpers should no longer use a singleton registry', E_USER_DEPRECATED); - if (null === static::$instance) { - static::$instance = new static(); - } - - return static::$instance; - } - - /** - * Unset the singleton - * - * Primarily useful for testing purposes; sets {@link $instance} to null. - * - * @return void - */ - public static function unsetRegistry() - { - trigger_error('Placeholder view helpers should no longer use a singleton registry', E_USER_DEPRECATED); - static::$instance = null; - } - /** * Set the container for an item in the registry * From 3eebe5fe556b178ce6b84fa12d9079e2bb4114db Mon Sep 17 00:00:00 2001 From: George Steel Date: Tue, 1 Feb 2022 16:52:24 +0000 Subject: [PATCH 07/58] Removes tests targeting deprecated and removed methods Signed-off-by: George Steel --- psalm-baseline.xml | 10 ---------- test/Helper/GravatarTest.php | 30 ------------------------------ 2 files changed, 40 deletions(-) diff --git a/psalm-baseline.xml b/psalm-baseline.xml index 8b2de156b..2165d4b2b 100644 --- a/psalm-baseline.xml +++ b/psalm-baseline.xml @@ -1447,9 +1447,6 @@ - - null === static::$instance - new $this->containerClass($value) @@ -1472,9 +1469,6 @@ (string) $key (string) $key - - new static() - @@ -2361,10 +2355,6 @@ - - getAttribs - setAttribs - $value $value diff --git a/test/Helper/GravatarTest.php b/test/Helper/GravatarTest.php index 0f5cd8c23..e2d423e49 100644 --- a/test/Helper/GravatarTest.php +++ b/test/Helper/GravatarTest.php @@ -274,34 +274,4 @@ public function testEmailIsProperlyNormalized(): void $this->helper->__invoke('Example@Example.com ')->getEmail() ); } - - public function testSetAttribsIsDeprecated(): void - { - $this->expectDeprecation(); - - $this->helper->setAttribs([]); - } - - public function testSetAttribsDocCommentHasDeprecated(): void - { - $method = new ReflectionMethod($this->helper, 'setAttribs'); - $comment = $method->getDocComment(); - - $this->assertStringContainsString('@deprecated', $comment); - } - - public function testGetAttribsIsDeprecated(): void - { - $this->expectDeprecation(); - - $this->helper->getAttribs(); - } - - public function testGetAttribsDocCommentHasDeprecated(): void - { - $method = new ReflectionMethod($this->helper, 'getAttribs'); - $comment = $method->getDocComment(); - - $this->assertStringContainsString('@deprecated', $comment); - } } From ddb4884aeb8d0092dc30ad8c689f19695c010d87 Mon Sep 17 00:00:00 2001 From: George Steel Date: Tue, 1 Feb 2022 17:03:06 +0000 Subject: [PATCH 08/58] Applies CS Fixes Signed-off-by: George Steel --- src/Helper/Gravatar.php | 3 --- src/Helper/Placeholder/Registry.php | 3 --- test/Helper/GravatarTest.php | 1 - 3 files changed, 7 deletions(-) diff --git a/src/Helper/Gravatar.php b/src/Helper/Gravatar.php index 8776a2b2c..984a597e0 100644 --- a/src/Helper/Gravatar.php +++ b/src/Helper/Gravatar.php @@ -12,13 +12,10 @@ use function sprintf; use function str_replace; use function strtolower; -use function trigger_error; use function trim; use function ucwords; use function urlencode; -use const E_USER_DEPRECATED; - /** * Helper for retrieving avatars from gravatar.com */ diff --git a/src/Helper/Placeholder/Registry.php b/src/Helper/Placeholder/Registry.php index 303216f3f..ae3dc4abd 100644 --- a/src/Helper/Placeholder/Registry.php +++ b/src/Helper/Placeholder/Registry.php @@ -12,9 +12,6 @@ use function class_parents; use function in_array; use function sprintf; -use function trigger_error; - -use const E_USER_DEPRECATED; /** * Registry for placeholder containers diff --git a/test/Helper/GravatarTest.php b/test/Helper/GravatarTest.php index e2d423e49..d763d94e4 100644 --- a/test/Helper/GravatarTest.php +++ b/test/Helper/GravatarTest.php @@ -8,7 +8,6 @@ use Laminas\View\Helper\Gravatar; use Laminas\View\Renderer\PhpRenderer as View; use PHPUnit\Framework\TestCase; -use ReflectionMethod; use function method_exists; use function strtoupper; From 6e623ccabfcd26999ce836990e5157125b58aede Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Micha=C5=82=20Bundyra?= Date: Tue, 8 Mar 2022 15:58:45 +0000 Subject: [PATCH 09/58] Message against the war, in Russian and English MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit 🇷🇺 Русским гражданам Мы, участники Laminas, родились и живем в разных странах. У многих из нас есть друзья, родственники и коллеги как в России, так и в Украине. Некоторые из нас родились в России. Некоторые из нас живут в России. У некоторых бабушки и дедушки сражались с фашистами во Второй мировой войне. Здесь никто не поддерживает фашизм. У одного из нас есть украинская родственница, которая спаслась из дома вместе с сыном. Поезд задержался из-за бомбежки на дороге впереди. У нас есть друзья, которые прячутся в бомбоубежищах. Мы с тревогой ждем весточки от них после воздушных налетов, которые беспорядочно наносят удары и попадают по больницам, школам, детским садам и домам. Мы не берем это из каких-либо СМИ. Мы наблюдаем это напрямую. Вы доверяете нам достаточно, чтоб использовать наши программы, и мы просим вас довериться нам вновь. Мы нуждаемся в помощи. Выходите и протестуйте против этой бесполезной войны. Остановите кровопролитие. Скажите "Нет войне!" 🇺🇸 To Citizens of Russia We at Laminas come from all over the world. Many of us have friends, family and colleagues in both Russia and Ukraine. Some of us were born in Russia. Some of us currently live in Russia. Some have grandparents who fought Nazis in World War II. Nobody here supports fascism. One team member has a Ukrainian relative who fled her home with her son. The train was delayed due to bombing on the road ahead. We have friends who are hiding in bomb shelters. We anxiously follow up on them after the air raids, which indiscriminately fire at hospitals, schools, kindergartens and houses. Were not taking this from any media. These are our actual experiences. You trust us enough to use our software. We ask that you trust us to say the truth on this. We need your help. Go out and protest this unnecessary war. Stop the bloodshed. Say "stop the war!" Signed-off-by: Michał Bundyra --- README.md | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/README.md b/README.md index d4eb109dd..6d735e277 100644 --- a/README.md +++ b/README.md @@ -2,6 +2,22 @@ [![Build Status](https://github.com/laminas/laminas-view/workflows/Continuous%20Integration/badge.svg)](https://github.com/laminas/laminas-view/actions?query=workflow%3A"Continuous+Integration") +> ## 🇷🇺 Русским гражданам +> +> Мы, участники Laminas, родились и живем в разных странах. У многих из нас есть друзья, родственники и коллеги как в России, так и в Украине. Некоторые из нас родились в России. Некоторые из нас живут в России. У некоторых бабушки и дедушки сражались с фашистами во Второй мировой войне. Здесь никто не поддерживает фашизм. +> +> У одного из нас есть украинская родственница, которая спаслась из дома вместе с сыном. Поезд задержался из-за бомбежки на дороге впереди. У нас есть друзья, которые прячутся в бомбоубежищах. Мы с тревогой ждем весточки от них после воздушных налетов, которые беспорядочно наносят удары и попадают по больницам, школам, детским садам и домам. Мы не берем это из каких-либо СМИ. Мы наблюдаем это напрямую. +> +> Вы доверяете нам достаточно, чтоб использовать наши программы, и мы просим вас довериться нам вновь. Мы нуждаемся в помощи. Выходите и протестуйте против этой бесполезной войны. Остановите кровопролитие. Скажите "Нет войне!" +> +> ## 🇺🇸 To Citizens of Russia +> +> We at Laminas come from all over the world. Many of us have friends, family and colleagues in both Russia and Ukraine. Some of us were born in Russia. Some of us currently live in Russia. Some have grandparents who fought Nazis in World War II. Nobody here supports fascism. +> +> One team member has a Ukrainian relative who fled her home with her son. The train was delayed due to bombing on the road ahead. We have friends who are hiding in bomb shelters. We anxiously follow up on them after the air raids, which indiscriminately fire at hospitals, schools, kindergartens and houses. We're not taking this from any media. These are our actual experiences. +> +> You trust us enough to use our software. We ask that you trust us to say the truth on this. We need your help. Go out and protest this unnecessary war. Stop the bloodshed. Say "stop the war!" + laminas-view provides the “View” layer of the Laminas MVC system. It is a multi-tiered system allowing a variety of mechanisms for extension, substitution, and more. From c25b97e2fc7fa5b5fec720fd46f43fca11ceb397 Mon Sep 17 00:00:00 2001 From: George Steel Date: Wed, 23 Mar 2022 14:11:03 +0000 Subject: [PATCH 10/58] Resets composer.lock after merge into 3.0.x Signed-off-by: George Steel --- composer.json | 3 +- composer.lock | 422 +++++++++++++++++++++++++------------------------- 2 files changed, 217 insertions(+), 208 deletions(-) diff --git a/composer.json b/composer.json index 2fcc7df3e..c9459e283 100644 --- a/composer.json +++ b/composer.json @@ -21,7 +21,8 @@ "php": "7.4" }, "allow-plugins": { - "dealerdirect/phpcodesniffer-composer-installer": true + "dealerdirect/phpcodesniffer-composer-installer": true, + "composer/package-versions-deprecated": true } }, "require": { diff --git a/composer.lock b/composer.lock index f02a21769..d93be8639 100644 --- a/composer.lock +++ b/composer.lock @@ -44,33 +44,33 @@ }, { "name": "laminas/laminas-escaper", - "version": "2.9.0", + "version": "2.10.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-escaper.git", - "reference": "891ad70986729e20ed2e86355fcf93c9dc238a5f" + "reference": "58af67282db37d24e584a837a94ee55b9c7552be" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-escaper/zipball/891ad70986729e20ed2e86355fcf93c9dc238a5f", - "reference": "891ad70986729e20ed2e86355fcf93c9dc238a5f", + "url": "https://api.github.com/repos/laminas/laminas-escaper/zipball/58af67282db37d24e584a837a94ee55b9c7552be", + "reference": "58af67282db37d24e584a837a94ee55b9c7552be", "shasum": "" }, "require": { - "php": "^7.3 || ~8.0.0 || ~8.1.0" + "ext-ctype": "*", + "ext-mbstring": "*", + "php": "^7.4 || ~8.0.0 || ~8.1.0" }, "conflict": { "zendframework/zend-escaper": "*" }, "require-dev": { + "infection/infection": "^0.26.6", "laminas/laminas-coding-standard": "~2.3.0", - "phpunit/phpunit": "^9.3", - "psalm/plugin-phpunit": "^0.12.2", - "vimeo/psalm": "^3.16" - }, - "suggest": { - "ext-iconv": "*", - "ext-mbstring": "*" + "maglnet/composer-require-checker": "^3.8.0", + "phpunit/phpunit": "^9.5.18", + "psalm/plugin-phpunit": "^0.16.1", + "vimeo/psalm": "^4.22.0" }, "type": "library", "autoload": { @@ -102,7 +102,7 @@ "type": "community_bridge" } ], - "time": "2021-09-02T17:10:53+00:00" + "time": "2022-03-08T20:15:36+00:00" }, { "name": "laminas/laminas-eventmanager", @@ -428,16 +428,16 @@ "packages-dev": [ { "name": "amphp/amp", - "version": "v2.6.1", + "version": "v2.6.2", "source": { "type": "git", "url": "https://github.com/amphp/amp.git", - "reference": "c5fc66a78ee38d7ac9195a37bacaf940eb3f65ae" + "reference": "9d5100cebffa729aaffecd3ad25dc5aeea4f13bb" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/amphp/amp/zipball/c5fc66a78ee38d7ac9195a37bacaf940eb3f65ae", - "reference": "c5fc66a78ee38d7ac9195a37bacaf940eb3f65ae", + "url": "https://api.github.com/repos/amphp/amp/zipball/9d5100cebffa729aaffecd3ad25dc5aeea4f13bb", + "reference": "9d5100cebffa729aaffecd3ad25dc5aeea4f13bb", "shasum": "" }, "require": { @@ -459,13 +459,13 @@ } }, "autoload": { - "psr-4": { - "Amp\\": "lib" - }, "files": [ "lib/functions.php", "lib/Internal/functions.php" - ] + ], + "psr-4": { + "Amp\\": "lib" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -490,7 +490,7 @@ } ], "description": "A non-blocking concurrency framework for PHP applications.", - "homepage": "http://amphp.org/amp", + "homepage": "https://amphp.org/amp", "keywords": [ "async", "asynchronous", @@ -505,7 +505,7 @@ "support": { "irc": "irc://irc.freenode.org/amphp", "issues": "https://github.com/amphp/amp/issues", - "source": "https://github.com/amphp/amp/tree/v2.6.1" + "source": "https://github.com/amphp/amp/tree/v2.6.2" }, "funding": [ { @@ -513,7 +513,7 @@ "type": "github" } ], - "time": "2021-09-23T18:43:08+00:00" + "time": "2022-02-20T17:52:18+00:00" }, { "name": "amphp/byte-stream", @@ -710,30 +710,30 @@ }, { "name": "composer/pcre", - "version": "1.0.1", + "version": "3.0.0", "source": { "type": "git", "url": "https://github.com/composer/pcre.git", - "reference": "67a32d7d6f9f560b726ab25a061b38ff3a80c560" + "reference": "e300eb6c535192decd27a85bc72a9290f0d6b3bd" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/pcre/zipball/67a32d7d6f9f560b726ab25a061b38ff3a80c560", - "reference": "67a32d7d6f9f560b726ab25a061b38ff3a80c560", + "url": "https://api.github.com/repos/composer/pcre/zipball/e300eb6c535192decd27a85bc72a9290f0d6b3bd", + "reference": "e300eb6c535192decd27a85bc72a9290f0d6b3bd", "shasum": "" }, "require": { - "php": "^5.3.2 || ^7.0 || ^8.0" + "php": "^7.4 || ^8.0" }, "require-dev": { "phpstan/phpstan": "^1.3", "phpstan/phpstan-strict-rules": "^1.1", - "symfony/phpunit-bridge": "^4.2 || ^5" + "symfony/phpunit-bridge": "^5" }, "type": "library", "extra": { "branch-alias": { - "dev-main": "1.x-dev" + "dev-main": "3.x-dev" } }, "autoload": { @@ -761,7 +761,7 @@ ], "support": { "issues": "https://github.com/composer/pcre/issues", - "source": "https://github.com/composer/pcre/tree/1.0.1" + "source": "https://github.com/composer/pcre/tree/3.0.0" }, "funding": [ { @@ -777,20 +777,20 @@ "type": "tidelift" } ], - "time": "2022-01-21T20:24:37+00:00" + "time": "2022-02-25T20:21:48+00:00" }, { "name": "composer/semver", - "version": "3.2.9", + "version": "3.3.1", "source": { "type": "git", "url": "https://github.com/composer/semver.git", - "reference": "a951f614bd64dcd26137bc9b7b2637ddcfc57649" + "reference": "5d8e574bb0e69188786b8ef77d43341222a41a71" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/semver/zipball/a951f614bd64dcd26137bc9b7b2637ddcfc57649", - "reference": "a951f614bd64dcd26137bc9b7b2637ddcfc57649", + "url": "https://api.github.com/repos/composer/semver/zipball/5d8e574bb0e69188786b8ef77d43341222a41a71", + "reference": "5d8e574bb0e69188786b8ef77d43341222a41a71", "shasum": "" }, "require": { @@ -842,7 +842,7 @@ "support": { "irc": "irc://irc.freenode.org/composer", "issues": "https://github.com/composer/semver/issues", - "source": "https://github.com/composer/semver/tree/3.2.9" + "source": "https://github.com/composer/semver/tree/3.3.1" }, "funding": [ { @@ -858,24 +858,24 @@ "type": "tidelift" } ], - "time": "2022-02-04T13:58:43+00:00" + "time": "2022-03-16T11:22:07+00:00" }, { "name": "composer/xdebug-handler", - "version": "3.0.1", + "version": "3.0.3", "source": { "type": "git", "url": "https://github.com/composer/xdebug-handler.git", - "reference": "12f1b79476638a5615ed00ea6adbb269cec96fd8" + "reference": "ced299686f41dce890debac69273b47ffe98a40c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/xdebug-handler/zipball/12f1b79476638a5615ed00ea6adbb269cec96fd8", - "reference": "12f1b79476638a5615ed00ea6adbb269cec96fd8", + "url": "https://api.github.com/repos/composer/xdebug-handler/zipball/ced299686f41dce890debac69273b47ffe98a40c", + "reference": "ced299686f41dce890debac69273b47ffe98a40c", "shasum": "" }, "require": { - "composer/pcre": "^1", + "composer/pcre": "^1 || ^2 || ^3", "php": "^7.2.5 || ^8.0", "psr/log": "^1 || ^2 || ^3" }, @@ -908,7 +908,7 @@ "support": { "irc": "irc://irc.freenode.org/composer", "issues": "https://github.com/composer/xdebug-handler/issues", - "source": "https://github.com/composer/xdebug-handler/tree/3.0.1" + "source": "https://github.com/composer/xdebug-handler/tree/3.0.3" }, "funding": [ { @@ -924,7 +924,7 @@ "type": "tidelift" } ], - "time": "2022-01-04T18:29:42+00:00" + "time": "2022-02-25T21:32:43+00:00" }, { "name": "dealerdirect/phpcodesniffer-composer-installer", @@ -1040,29 +1040,30 @@ }, { "name": "doctrine/instantiator", - "version": "1.4.0", + "version": "1.4.1", "source": { "type": "git", "url": "https://github.com/doctrine/instantiator.git", - "reference": "d56bf6102915de5702778fe20f2de3b2fe570b5b" + "reference": "10dcfce151b967d20fde1b34ae6640712c3891bc" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/instantiator/zipball/d56bf6102915de5702778fe20f2de3b2fe570b5b", - "reference": "d56bf6102915de5702778fe20f2de3b2fe570b5b", + "url": "https://api.github.com/repos/doctrine/instantiator/zipball/10dcfce151b967d20fde1b34ae6640712c3891bc", + "reference": "10dcfce151b967d20fde1b34ae6640712c3891bc", "shasum": "" }, "require": { "php": "^7.1 || ^8.0" }, "require-dev": { - "doctrine/coding-standard": "^8.0", + "doctrine/coding-standard": "^9", "ext-pdo": "*", "ext-phar": "*", - "phpbench/phpbench": "^0.13 || 1.0.0-alpha2", - "phpstan/phpstan": "^0.12", - "phpstan/phpstan-phpunit": "^0.12", - "phpunit/phpunit": "^7.0 || ^8.0 || ^9.0" + "phpbench/phpbench": "^0.16 || ^1", + "phpstan/phpstan": "^1.4", + "phpstan/phpstan-phpunit": "^1", + "phpunit/phpunit": "^7.5 || ^8.5 || ^9.5", + "vimeo/psalm": "^4.22" }, "type": "library", "autoload": { @@ -1089,7 +1090,7 @@ ], "support": { "issues": "https://github.com/doctrine/instantiator/issues", - "source": "https://github.com/doctrine/instantiator/tree/1.4.0" + "source": "https://github.com/doctrine/instantiator/tree/1.4.1" }, "funding": [ { @@ -1105,7 +1106,7 @@ "type": "tidelift" } ], - "time": "2020-11-10T18:47:58+00:00" + "time": "2022-03-03T08:28:38+00:00" }, { "name": "felixfbecker/advanced-json-rpc", @@ -1210,16 +1211,16 @@ }, { "name": "laminas/laminas-authentication", - "version": "2.9.0", + "version": "2.10.1", "source": { "type": "git", "url": "https://github.com/laminas/laminas-authentication.git", - "reference": "cf611a6fe50b4e4905be22a4cd59ba303bc039fc" + "reference": "7308db03e11147fbf567b5004ac428bdaba267f9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-authentication/zipball/cf611a6fe50b4e4905be22a4cd59ba303bc039fc", - "reference": "cf611a6fe50b4e4905be22a4cd59ba303bc039fc", + "url": "https://api.github.com/repos/laminas/laminas-authentication/zipball/7308db03e11147fbf567b5004ac428bdaba267f9", + "reference": "7308db03e11147fbf567b5004ac428bdaba267f9", "shasum": "" }, "require": { @@ -1282,7 +1283,7 @@ "type": "community_bridge" } ], - "time": "2021-12-04T16:13:05+00:00" + "time": "2022-03-09T23:07:57+00:00" }, { "name": "laminas/laminas-coding-standard", @@ -1550,16 +1551,16 @@ }, { "name": "laminas/laminas-filter", - "version": "2.13.2", + "version": "2.14.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-filter.git", - "reference": "3da1df596b023fb0387a1dbb0e77e536afd9d1af" + "reference": "98a126b8cd069a446054680c9be5f37a61f6dc17" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-filter/zipball/3da1df596b023fb0387a1dbb0e77e536afd9d1af", - "reference": "3da1df596b023fb0387a1dbb0e77e536afd9d1af", + "url": "https://api.github.com/repos/laminas/laminas-filter/zipball/98a126b8cd069a446054680c9be5f37a61f6dc17", + "reference": "98a126b8cd069a446054680c9be5f37a61f6dc17", "shasum": "" }, "require": { @@ -1625,7 +1626,7 @@ "type": "community_bridge" } ], - "time": "2022-02-07T13:14:03+00:00" + "time": "2022-02-22T23:09:15+00:00" }, { "name": "laminas/laminas-http", @@ -1694,22 +1695,22 @@ }, { "name": "laminas/laminas-i18n", - "version": "2.13.0", + "version": "2.14.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-i18n.git", - "reference": "b3a55d05818ed37ed18e76c103727e95e32cf591" + "reference": "1fa15c41b683bedb2a846af54491868ddc73db38" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-i18n/zipball/b3a55d05818ed37ed18e76c103727e95e32cf591", - "reference": "b3a55d05818ed37ed18e76c103727e95e32cf591", + "url": "https://api.github.com/repos/laminas/laminas-i18n/zipball/1fa15c41b683bedb2a846af54491868ddc73db38", + "reference": "1fa15c41b683bedb2a846af54491868ddc73db38", "shasum": "" }, "require": { "ext-intl": "*", "laminas/laminas-stdlib": "^2.7 || ^3.0", - "php": "^7.3 || ~8.0.0 || ~8.1.0" + "php": "^7.4 || ~8.0.0 || ~8.1.0" }, "conflict": { "phpspec/prophecy": "<1.9.0", @@ -1719,14 +1720,17 @@ "laminas/laminas-cache": "^3.1.2", "laminas/laminas-cache-storage-adapter-memory": "^2.0.0", "laminas/laminas-cache-storage-deprecated-factory": "^1.0.0", - "laminas/laminas-coding-standard": "~1.0.0", + "laminas/laminas-coding-standard": "~2.3.0", "laminas/laminas-config": "^3.4.0", "laminas/laminas-eventmanager": "^3.4.0", "laminas/laminas-filter": "^2.10.0", "laminas/laminas-servicemanager": "^3.7.0", "laminas/laminas-validator": "^2.14.0", "laminas/laminas-view": "^2.12.0", - "phpunit/phpunit": "^9.3" + "phpspec/prophecy-phpunit": "^2.0", + "phpunit/phpunit": "^9.3", + "psalm/plugin-phpunit": "^0.16.1", + "vimeo/psalm": "^4.21" }, "suggest": { "laminas/laminas-cache": "You should install this package to cache the translations", @@ -1774,7 +1778,7 @@ "type": "community_bridge" } ], - "time": "2021-12-06T00:44:40+00:00" + "time": "2022-02-21T20:41:26+00:00" }, { "name": "laminas/laminas-loader", @@ -1904,16 +1908,16 @@ }, { "name": "laminas/laminas-mvc", - "version": "3.3.2", + "version": "3.3.3", "source": { "type": "git", "url": "https://github.com/laminas/laminas-mvc.git", - "reference": "16bb3bc6bed6cc42ef4d2e5e7dc4a5c97841c6a2" + "reference": "7ff2bfbe64048aa83c6d1c7edcbab849123f0150" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-mvc/zipball/16bb3bc6bed6cc42ef4d2e5e7dc4a5c97841c6a2", - "reference": "16bb3bc6bed6cc42ef4d2e5e7dc4a5c97841c6a2", + "url": "https://api.github.com/repos/laminas/laminas-mvc/zipball/7ff2bfbe64048aa83c6d1c7edcbab849123f0150", + "reference": "7ff2bfbe64048aa83c6d1c7edcbab849123f0150", "shasum": "" }, "require": { @@ -1982,20 +1986,20 @@ "type": "community_bridge" } ], - "time": "2022-02-08T21:08:00+00:00" + "time": "2022-02-21T20:21:58+00:00" }, { "name": "laminas/laminas-mvc-i18n", - "version": "1.3.0", + "version": "1.3.1", "source": { "type": "git", "url": "https://github.com/laminas/laminas-mvc-i18n.git", - "reference": "1df255e2840eafdd814f5f7f4a46ef192aa5f880" + "reference": "3f6c81d839507dee8bbf74a09a9bfc65ecd3bb88" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-mvc-i18n/zipball/1df255e2840eafdd814f5f7f4a46ef192aa5f880", - "reference": "1df255e2840eafdd814f5f7f4a46ef192aa5f880", + "url": "https://api.github.com/repos/laminas/laminas-mvc-i18n/zipball/3f6c81d839507dee8bbf74a09a9bfc65ecd3bb88", + "reference": "3f6c81d839507dee8bbf74a09a9bfc65ecd3bb88", "shasum": "" }, "require": { @@ -2059,7 +2063,7 @@ "type": "community_bridge" } ], - "time": "2021-11-30T17:32:48+00:00" + "time": "2022-02-25T14:13:55+00:00" }, { "name": "laminas/laminas-mvc-plugin-flashmessenger", @@ -2132,16 +2136,16 @@ }, { "name": "laminas/laminas-navigation", - "version": "2.13.1", + "version": "2.13.2", "source": { "type": "git", "url": "https://github.com/laminas/laminas-navigation.git", - "reference": "a4343098b50942df1edcc2b035780068bac17ed5" + "reference": "ca7c4df621bba21494b62722c46cd9326ca3e360" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-navigation/zipball/a4343098b50942df1edcc2b035780068bac17ed5", - "reference": "a4343098b50942df1edcc2b035780068bac17ed5", + "url": "https://api.github.com/repos/laminas/laminas-navigation/zipball/ca7c4df621bba21494b62722c46cd9326ca3e360", + "reference": "ca7c4df621bba21494b62722c46cd9326ca3e360", "shasum": "" }, "require": { @@ -2208,7 +2212,7 @@ "type": "community_bridge" } ], - "time": "2021-12-12T19:57:52+00:00" + "time": "2022-02-16T21:41:34+00:00" }, { "name": "laminas/laminas-paginator", @@ -2426,16 +2430,16 @@ }, { "name": "laminas/laminas-session", - "version": "2.12.0", + "version": "2.12.1", "source": { "type": "git", "url": "https://github.com/laminas/laminas-session.git", - "reference": "fc538bba5196e3b5937ae7db3c713fc7c0829881" + "reference": "888c6a344e9a4c9f34ab6e09346640eac9be3fcf" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-session/zipball/fc538bba5196e3b5937ae7db3c713fc7c0829881", - "reference": "fc538bba5196e3b5937ae7db3c713fc7c0829881", + "url": "https://api.github.com/repos/laminas/laminas-session/zipball/888c6a344e9a4c9f34ab6e09346640eac9be3fcf", + "reference": "888c6a344e9a4c9f34ab6e09346640eac9be3fcf", "shasum": "" }, "require": { @@ -2504,7 +2508,7 @@ "type": "community_bridge" } ], - "time": "2021-09-21T19:25:14+00:00" + "time": "2022-02-15T16:38:29+00:00" }, { "name": "laminas/laminas-uri", @@ -2566,16 +2570,16 @@ }, { "name": "laminas/laminas-validator", - "version": "2.16.0", + "version": "2.17.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-validator.git", - "reference": "329900ab7674c198e91e85b2e09080cdf493ce07" + "reference": "bdd503adc83d814a5c94e598ea0eb9fc7ca56339" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-validator/zipball/329900ab7674c198e91e85b2e09080cdf493ce07", - "reference": "329900ab7674c198e91e85b2e09080cdf493ce07", + "url": "https://api.github.com/repos/laminas/laminas-validator/zipball/bdd503adc83d814a5c94e598ea0eb9fc7ca56339", + "reference": "bdd503adc83d814a5c94e598ea0eb9fc7ca56339", "shasum": "" }, "require": { @@ -2652,30 +2656,30 @@ "type": "community_bridge" } ], - "time": "2022-01-21T14:30:01+00:00" + "time": "2022-03-08T18:16:51+00:00" }, { "name": "laminas/laminas-zendframework-bridge", - "version": "1.4.1", + "version": "1.5.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-zendframework-bridge.git", - "reference": "88bf037259869891afce6504cacc4f8a07b24d0f" + "reference": "7f049390b756d34ba5940a8fb47634fbb51f79ab" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-zendframework-bridge/zipball/88bf037259869891afce6504cacc4f8a07b24d0f", - "reference": "88bf037259869891afce6504cacc4f8a07b24d0f", + "url": "https://api.github.com/repos/laminas/laminas-zendframework-bridge/zipball/7f049390b756d34ba5940a8fb47634fbb51f79ab", + "reference": "7f049390b756d34ba5940a8fb47634fbb51f79ab", "shasum": "" }, "require": { - "php": "^7.3 || ~8.0.0 || ~8.1.0" + "php": ">=7.4, <8.2" }, "require-dev": { - "phpunit/phpunit": "^9.3", - "psalm/plugin-phpunit": "^0.15.1", - "squizlabs/php_codesniffer": "^3.5", - "vimeo/psalm": "^4.6" + "phpunit/phpunit": "^9.5.14", + "psalm/plugin-phpunit": "^0.15.2", + "squizlabs/php_codesniffer": "^3.6.2", + "vimeo/psalm": "^4.21.0" }, "type": "library", "extra": { @@ -2714,29 +2718,33 @@ "type": "community_bridge" } ], - "time": "2021-12-21T14:34:37+00:00" + "time": "2022-02-22T22:17:01+00:00" }, { "name": "myclabs/deep-copy", - "version": "1.10.2", + "version": "1.11.0", "source": { "type": "git", "url": "https://github.com/myclabs/DeepCopy.git", - "reference": "776f831124e9c62e1a2c601ecc52e776d8bb7220" + "reference": "14daed4296fae74d9e3201d2c4925d1acb7aa614" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/776f831124e9c62e1a2c601ecc52e776d8bb7220", - "reference": "776f831124e9c62e1a2c601ecc52e776d8bb7220", + "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/14daed4296fae74d9e3201d2c4925d1acb7aa614", + "reference": "14daed4296fae74d9e3201d2c4925d1acb7aa614", "shasum": "" }, "require": { "php": "^7.1 || ^8.0" }, + "conflict": { + "doctrine/collections": "<1.6.8", + "doctrine/common": "<2.13.3 || >=3,<3.2.2" + }, "require-dev": { - "doctrine/collections": "^1.0", - "doctrine/common": "^2.6", - "phpunit/phpunit": "^7.1" + "doctrine/collections": "^1.6.8", + "doctrine/common": "^2.13.3 || ^3.2.2", + "phpunit/phpunit": "^7.5.20 || ^8.5.23 || ^9.5.13" }, "type": "library", "autoload": { @@ -2761,7 +2769,7 @@ ], "support": { "issues": "https://github.com/myclabs/DeepCopy/issues", - "source": "https://github.com/myclabs/DeepCopy/tree/1.10.2" + "source": "https://github.com/myclabs/DeepCopy/tree/1.11.0" }, "funding": [ { @@ -2769,7 +2777,7 @@ "type": "tidelift" } ], - "time": "2020-11-13T09:40:50+00:00" + "time": "2022-03-03T13:19:32+00:00" }, { "name": "netresearch/jsonmapper", @@ -2993,16 +3001,16 @@ }, { "name": "phar-io/version", - "version": "3.1.1", + "version": "3.2.1", "source": { "type": "git", "url": "https://github.com/phar-io/version.git", - "reference": "15a90844ad40f127afd244c0cad228de2a80052a" + "reference": "4f7fd7836c6f332bb2933569e566a0d6c4cbed74" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phar-io/version/zipball/15a90844ad40f127afd244c0cad228de2a80052a", - "reference": "15a90844ad40f127afd244c0cad228de2a80052a", + "url": "https://api.github.com/repos/phar-io/version/zipball/4f7fd7836c6f332bb2933569e566a0d6c4cbed74", + "reference": "4f7fd7836c6f332bb2933569e566a0d6c4cbed74", "shasum": "" }, "require": { @@ -3038,9 +3046,9 @@ "description": "Library for handling version information and constraints", "support": { "issues": "https://github.com/phar-io/version/issues", - "source": "https://github.com/phar-io/version/tree/3.1.1" + "source": "https://github.com/phar-io/version/tree/3.2.1" }, - "time": "2022-02-07T21:56:48+00:00" + "time": "2022-02-21T01:04:05+00:00" }, { "name": "phpdocumentor/reflection-common", @@ -3372,16 +3380,16 @@ }, { "name": "phpunit/php-code-coverage", - "version": "9.2.10", + "version": "9.2.15", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "d5850aaf931743067f4bfc1ae4cbd06468400687" + "reference": "2e9da11878c4202f97915c1cb4bb1ca318a63f5f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/d5850aaf931743067f4bfc1ae4cbd06468400687", - "reference": "d5850aaf931743067f4bfc1ae4cbd06468400687", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/2e9da11878c4202f97915c1cb4bb1ca318a63f5f", + "reference": "2e9da11878c4202f97915c1cb4bb1ca318a63f5f", "shasum": "" }, "require": { @@ -3437,7 +3445,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", - "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.10" + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.15" }, "funding": [ { @@ -3445,7 +3453,7 @@ "type": "github" } ], - "time": "2021-12-05T09:12:13+00:00" + "time": "2022-03-07T09:28:20+00:00" }, { "name": "phpunit/php-file-iterator", @@ -3690,16 +3698,16 @@ }, { "name": "phpunit/phpunit", - "version": "9.5.13", + "version": "9.5.19", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "597cb647654ede35e43b137926dfdfef0fb11743" + "reference": "35ea4b7f3acabb26f4bb640f8c30866c401da807" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/597cb647654ede35e43b137926dfdfef0fb11743", - "reference": "597cb647654ede35e43b137926dfdfef0fb11743", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/35ea4b7f3acabb26f4bb640f8c30866c401da807", + "reference": "35ea4b7f3acabb26f4bb640f8c30866c401da807", "shasum": "" }, "require": { @@ -3715,7 +3723,7 @@ "phar-io/version": "^3.0.2", "php": ">=7.3", "phpspec/prophecy": "^1.12.1", - "phpunit/php-code-coverage": "^9.2.7", + "phpunit/php-code-coverage": "^9.2.13", "phpunit/php-file-iterator": "^3.0.5", "phpunit/php-invoker": "^3.1.1", "phpunit/php-text-template": "^2.0.3", @@ -3729,7 +3737,7 @@ "sebastian/global-state": "^5.0.1", "sebastian/object-enumerator": "^4.0.3", "sebastian/resource-operations": "^3.0.3", - "sebastian/type": "^2.3.4", + "sebastian/type": "^3.0", "sebastian/version": "^3.0.2" }, "require-dev": { @@ -3777,7 +3785,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", - "source": "https://github.com/sebastianbergmann/phpunit/tree/9.5.13" + "source": "https://github.com/sebastianbergmann/phpunit/tree/9.5.19" }, "funding": [ { @@ -3789,7 +3797,7 @@ "type": "github" } ], - "time": "2022-01-24T07:33:35+00:00" + "time": "2022-03-15T09:57:31+00:00" }, { "name": "psalm/plugin-phpunit", @@ -4407,16 +4415,16 @@ }, { "name": "sebastian/global-state", - "version": "5.0.4", + "version": "5.0.5", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/global-state.git", - "reference": "19c519631c5a511b7ed0ad64a6713fdb3fd25fe4" + "reference": "0ca8db5a5fc9c8646244e629625ac486fa286bf2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/19c519631c5a511b7ed0ad64a6713fdb3fd25fe4", - "reference": "19c519631c5a511b7ed0ad64a6713fdb3fd25fe4", + "url": "https://api.github.com/repos/sebastianbergmann/global-state/zipball/0ca8db5a5fc9c8646244e629625ac486fa286bf2", + "reference": "0ca8db5a5fc9c8646244e629625ac486fa286bf2", "shasum": "" }, "require": { @@ -4459,7 +4467,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/global-state/issues", - "source": "https://github.com/sebastianbergmann/global-state/tree/5.0.4" + "source": "https://github.com/sebastianbergmann/global-state/tree/5.0.5" }, "funding": [ { @@ -4467,7 +4475,7 @@ "type": "github" } ], - "time": "2022-02-10T07:01:19+00:00" + "time": "2022-02-14T08:28:10+00:00" }, { "name": "sebastian/lines-of-code", @@ -4758,28 +4766,28 @@ }, { "name": "sebastian/type", - "version": "2.3.4", + "version": "3.0.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/type.git", - "reference": "b8cd8a1c753c90bc1a0f5372170e3e489136f914" + "reference": "b233b84bc4465aff7b57cf1c4bc75c86d00d6dad" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/b8cd8a1c753c90bc1a0f5372170e3e489136f914", - "reference": "b8cd8a1c753c90bc1a0f5372170e3e489136f914", + "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/b233b84bc4465aff7b57cf1c4bc75c86d00d6dad", + "reference": "b233b84bc4465aff7b57cf1c4bc75c86d00d6dad", "shasum": "" }, "require": { "php": ">=7.3" }, "require-dev": { - "phpunit/phpunit": "^9.3" + "phpunit/phpunit": "^9.5" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "2.3-dev" + "dev-master": "3.0-dev" } }, "autoload": { @@ -4802,7 +4810,7 @@ "homepage": "https://github.com/sebastianbergmann/type", "support": { "issues": "https://github.com/sebastianbergmann/type/issues", - "source": "https://github.com/sebastianbergmann/type/tree/2.3.4" + "source": "https://github.com/sebastianbergmann/type/tree/3.0.0" }, "funding": [ { @@ -4810,7 +4818,7 @@ "type": "github" } ], - "time": "2021-06-15T12:49:02+00:00" + "time": "2022-03-15T09:54:48+00:00" }, { "name": "sebastian/version", @@ -4867,32 +4875,32 @@ }, { "name": "slevomat/coding-standard", - "version": "7.0.18", + "version": "7.0.19", "source": { "type": "git", "url": "https://github.com/slevomat/coding-standard.git", - "reference": "b81ac84f41a4797dc25c8ede1b0718e2a74be0fc" + "reference": "bef66a43815bbf9b5f49775e9ded3f7c6ba0cc37" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/slevomat/coding-standard/zipball/b81ac84f41a4797dc25c8ede1b0718e2a74be0fc", - "reference": "b81ac84f41a4797dc25c8ede1b0718e2a74be0fc", + "url": "https://api.github.com/repos/slevomat/coding-standard/zipball/bef66a43815bbf9b5f49775e9ded3f7c6ba0cc37", + "reference": "bef66a43815bbf9b5f49775e9ded3f7c6ba0cc37", "shasum": "" }, "require": { "dealerdirect/phpcodesniffer-composer-installer": "^0.6.2 || ^0.7", "php": "^7.1 || ^8.0", "phpstan/phpdoc-parser": "^1.0.0", - "squizlabs/php_codesniffer": "^3.6.1" + "squizlabs/php_codesniffer": "^3.6.2" }, "require-dev": { - "phing/phing": "2.17.0", - "php-parallel-lint/php-parallel-lint": "1.3.1", - "phpstan/phpstan": "1.2.0", + "phing/phing": "2.17.2", + "php-parallel-lint/php-parallel-lint": "1.3.2", + "phpstan/phpstan": "1.4.6", "phpstan/phpstan-deprecation-rules": "1.0.0", "phpstan/phpstan-phpunit": "1.0.0", "phpstan/phpstan-strict-rules": "1.1.0", - "phpunit/phpunit": "7.5.20|8.5.21|9.5.10" + "phpunit/phpunit": "7.5.20|8.5.21|9.5.16" }, "type": "phpcodesniffer-standard", "extra": { @@ -4912,7 +4920,7 @@ "description": "Slevomat Coding Standard for PHP_CodeSniffer complements Consistence Coding Standard by providing sniffs with additional checks.", "support": { "issues": "https://github.com/slevomat/coding-standard/issues", - "source": "https://github.com/slevomat/coding-standard/tree/7.0.18" + "source": "https://github.com/slevomat/coding-standard/tree/7.0.19" }, "funding": [ { @@ -4924,7 +4932,7 @@ "type": "tidelift" } ], - "time": "2021-12-07T17:19:06+00:00" + "time": "2022-03-01T18:01:41+00:00" }, { "name": "squizlabs/php_codesniffer", @@ -4984,16 +4992,16 @@ }, { "name": "symfony/console", - "version": "v5.4.3", + "version": "v5.4.5", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "a2a86ec353d825c75856c6fd14fac416a7bdb6b8" + "reference": "d8111acc99876953f52fe16d4c50eb60940d49ad" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/a2a86ec353d825c75856c6fd14fac416a7bdb6b8", - "reference": "a2a86ec353d825c75856c6fd14fac416a7bdb6b8", + "url": "https://api.github.com/repos/symfony/console/zipball/d8111acc99876953f52fe16d4c50eb60940d49ad", + "reference": "d8111acc99876953f52fe16d4c50eb60940d49ad", "shasum": "" }, "require": { @@ -5063,7 +5071,7 @@ "terminal" ], "support": { - "source": "https://github.com/symfony/console/tree/v5.4.3" + "source": "https://github.com/symfony/console/tree/v5.4.5" }, "funding": [ { @@ -5079,7 +5087,7 @@ "type": "tidelift" } ], - "time": "2022-01-26T16:28:35+00:00" + "time": "2022-02-24T12:45:35+00:00" }, { "name": "symfony/deprecation-contracts", @@ -5150,7 +5158,7 @@ }, { "name": "symfony/polyfill-ctype", - "version": "v1.24.0", + "version": "v1.25.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-ctype.git", @@ -5182,12 +5190,12 @@ } }, "autoload": { - "psr-4": { - "Symfony\\Polyfill\\Ctype\\": "" - }, "files": [ "bootstrap.php" - ] + ], + "psr-4": { + "Symfony\\Polyfill\\Ctype\\": "" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -5212,7 +5220,7 @@ "portable" ], "support": { - "source": "https://github.com/symfony/polyfill-ctype/tree/v1.24.0" + "source": "https://github.com/symfony/polyfill-ctype/tree/v1.25.0" }, "funding": [ { @@ -5232,7 +5240,7 @@ }, { "name": "symfony/polyfill-intl-grapheme", - "version": "v1.24.0", + "version": "v1.25.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-grapheme.git", @@ -5293,7 +5301,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-intl-grapheme/tree/v1.24.0" + "source": "https://github.com/symfony/polyfill-intl-grapheme/tree/v1.25.0" }, "funding": [ { @@ -5313,7 +5321,7 @@ }, { "name": "symfony/polyfill-intl-normalizer", - "version": "v1.24.0", + "version": "v1.25.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-normalizer.git", @@ -5377,7 +5385,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-intl-normalizer/tree/v1.24.0" + "source": "https://github.com/symfony/polyfill-intl-normalizer/tree/v1.25.0" }, "funding": [ { @@ -5397,7 +5405,7 @@ }, { "name": "symfony/polyfill-mbstring", - "version": "v1.24.0", + "version": "v1.25.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-mbstring.git", @@ -5460,7 +5468,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.24.0" + "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.25.0" }, "funding": [ { @@ -5480,7 +5488,7 @@ }, { "name": "symfony/polyfill-php73", - "version": "v1.24.0", + "version": "v1.25.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php73.git", @@ -5539,7 +5547,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-php73/tree/v1.24.0" + "source": "https://github.com/symfony/polyfill-php73/tree/v1.25.0" }, "funding": [ { @@ -5559,16 +5567,16 @@ }, { "name": "symfony/polyfill-php80", - "version": "v1.24.0", + "version": "v1.25.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php80.git", - "reference": "57b712b08eddb97c762a8caa32c84e037892d2e9" + "reference": "4407588e0d3f1f52efb65fbe92babe41f37fe50c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/57b712b08eddb97c762a8caa32c84e037892d2e9", - "reference": "57b712b08eddb97c762a8caa32c84e037892d2e9", + "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/4407588e0d3f1f52efb65fbe92babe41f37fe50c", + "reference": "4407588e0d3f1f52efb65fbe92babe41f37fe50c", "shasum": "" }, "require": { @@ -5622,7 +5630,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-php80/tree/v1.24.0" + "source": "https://github.com/symfony/polyfill-php80/tree/v1.25.0" }, "funding": [ { @@ -5638,7 +5646,7 @@ "type": "tidelift" } ], - "time": "2021-09-13T13:58:33+00:00" + "time": "2022-03-04T08:16:47+00:00" }, { "name": "symfony/service-contracts", @@ -5756,12 +5764,12 @@ }, "type": "library", "autoload": { - "psr-4": { - "Symfony\\Component\\String\\": "" - }, "files": [ "Resources/functions.php" ], + "psr-4": { + "Symfony\\Component\\String\\": "" + }, "exclude-from-classmap": [ "/Tests/" ] @@ -5861,16 +5869,16 @@ }, { "name": "vimeo/psalm", - "version": "4.20.0", + "version": "4.22.0", "source": { "type": "git", "url": "https://github.com/vimeo/psalm.git", - "reference": "f82a70e7edfc6cf2705e9374c8a0b6a974a779ed" + "reference": "fc2c6ab4d5fa5d644d8617089f012f3bb84b8703" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/vimeo/psalm/zipball/f82a70e7edfc6cf2705e9374c8a0b6a974a779ed", - "reference": "f82a70e7edfc6cf2705e9374c8a0b6a974a779ed", + "url": "https://api.github.com/repos/vimeo/psalm/zipball/fc2c6ab4d5fa5d644d8617089f012f3bb84b8703", + "reference": "fc2c6ab4d5fa5d644d8617089f012f3bb84b8703", "shasum": "" }, "require": { @@ -5961,30 +5969,30 @@ ], "support": { "issues": "https://github.com/vimeo/psalm/issues", - "source": "https://github.com/vimeo/psalm/tree/4.20.0" + "source": "https://github.com/vimeo/psalm/tree/4.22.0" }, - "time": "2022-02-03T17:03:47+00:00" + "time": "2022-02-24T20:34:05+00:00" }, { "name": "webimpress/coding-standard", - "version": "1.2.3", + "version": "1.2.4", "source": { "type": "git", "url": "https://github.com/webimpress/coding-standard.git", - "reference": "7a71421c7fc85827488f10c4c510fe80f94d1a74" + "reference": "cd0c4b0b97440c337c1f7da17b524674ca2f9ca9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/webimpress/coding-standard/zipball/7a71421c7fc85827488f10c4c510fe80f94d1a74", - "reference": "7a71421c7fc85827488f10c4c510fe80f94d1a74", + "url": "https://api.github.com/repos/webimpress/coding-standard/zipball/cd0c4b0b97440c337c1f7da17b524674ca2f9ca9", + "reference": "cd0c4b0b97440c337c1f7da17b524674ca2f9ca9", "shasum": "" }, "require": { "php": "^7.3 || ^8.0", - "squizlabs/php_codesniffer": "^3.6.1" + "squizlabs/php_codesniffer": "^3.6.2" }, "require-dev": { - "phpunit/phpunit": "^9.5.10" + "phpunit/phpunit": "^9.5.13" }, "type": "phpcodesniffer-standard", "extra": { @@ -6010,7 +6018,7 @@ ], "support": { "issues": "https://github.com/webimpress/coding-standard/issues", - "source": "https://github.com/webimpress/coding-standard/tree/1.2.3" + "source": "https://github.com/webimpress/coding-standard/tree/1.2.4" }, "funding": [ { @@ -6018,7 +6026,7 @@ "type": "github" } ], - "time": "2021-10-28T21:18:17+00:00" + "time": "2022-02-15T19:52:12+00:00" }, { "name": "webimpress/safe-writer", From c79d221036981208cf79a6768ebc519cb3c322a5 Mon Sep 17 00:00:00 2001 From: George Steel Date: Sat, 8 Jan 2022 21:07:41 +0000 Subject: [PATCH 11/58] Console Removal WRT #101 - Removes Console Model and Renderer - Removes laminas-console from dev dependencies Signed-off-by: George Steel --- composer.json | 2 +- src/Model/ConsoleModel.php | 73 --------------- src/Renderer/ConsoleRenderer.php | 145 ----------------------------- test/Helper/UrlIntegrationTest.php | 18 ---- test/Model/ConsoleModelTest.php | 30 ------ 5 files changed, 1 insertion(+), 267 deletions(-) delete mode 100644 src/Model/ConsoleModel.php delete mode 100644 src/Renderer/ConsoleRenderer.php delete mode 100644 test/Model/ConsoleModelTest.php diff --git a/composer.json b/composer.json index c9459e283..3473d3847 100644 --- a/composer.json +++ b/composer.json @@ -41,7 +41,7 @@ "require-dev": { "laminas/laminas-authentication": "^2.5", "laminas/laminas-coding-standard": "~2.3.0", - "laminas/laminas-console": "^2.6", + "laminas/laminas-escaper": "^2.5", "laminas/laminas-feed": "^2.15", "laminas/laminas-filter": "^2.13.0", "laminas/laminas-http": "^2.15", diff --git a/src/Model/ConsoleModel.php b/src/Model/ConsoleModel.php deleted file mode 100644 index 4edfc1b09..000000000 --- a/src/Model/ConsoleModel.php +++ /dev/null @@ -1,73 +0,0 @@ -options['errorLevel'] = $errorLevel; - return $this; - } - - /** - * @return int - */ - public function getErrorLevel() - { - if (array_key_exists('errorLevel', $this->options)) { - return $this->options['errorLevel']; - } - } - - /** - * Set result text. - * - * @param string $text - * @return ConsoleModel - */ - public function setResult($text) - { - $this->setVariable(self::RESULT, $text); - return $this; - } - - /** - * Get result text. - * - * @return mixed - */ - public function getResult() - { - return $this->getVariable(self::RESULT); - } -} diff --git a/src/Renderer/ConsoleRenderer.php b/src/Renderer/ConsoleRenderer.php deleted file mode 100644 index da4eb946b..000000000 --- a/src/Renderer/ConsoleRenderer.php +++ /dev/null @@ -1,145 +0,0 @@ -init(); - } - - /** @return $this */ - public function setResolver(ResolverInterface $resolver) - { - return $this; - } - - /** - * Return the template engine object - * - * Returns the object instance, as it is its own template engine - * - * @return ConsoleRenderer - */ - public function getEngine() - { - return $this; - } - - /** - * Allow custom object initialization when extending ConsoleRenderer - * - * Triggered by {@link __construct() the constructor} as its final action. - * - * @return void - */ - public function init() - { - } - - /** - * Set filter chain - * - * @return ConsoleRenderer - */ - public function setFilterChain(FilterChain $filters) - { - $this->__filterChain = $filters; - return $this; - } - - /** - * Retrieve filter chain for post-filtering script content - * - * @return FilterChain - */ - public function getFilterChain() - { - if (null === $this->__filterChain) { - $this->__filterChain = new FilterChain(); - } - return $this->__filterChain; - } - - /** - * Recursively processes all ViewModels and returns output. - * - * @param string|ModelInterface $model A ViewModel instance. - * @param null|array|Traversable $values Values to use when rendering. If none - * provided, uses those in the composed - * variables container. - * @return string Console output. - */ - public function render($model, $values = null) - { - if (! $model instanceof ModelInterface) { - return ''; - } - - $result = ''; - $options = $model->getOptions(); - foreach ($options as $setting => $value) { - $method = 'set' . $setting; - if (method_exists($this, $method)) { - $this->$method($value); - } - unset($method, $setting, $value); - } - unset($options); - - $values = $model->getVariables(); - - if (isset($values['result'])) { - // filter and append the result - $result .= $this->getFilterChain()->filter($values['result']); - } - - if ($model->hasChildren()) { - // recursively render all children - foreach ($model->getChildren() as $child) { - $result .= $this->render($child, $values); - } - } - - return $result; - } - - /** - * @see \Laminas\View\Renderer\TreeRendererInterface - * - * @return bool - */ - public function canRenderTrees() - { - return true; - } -} diff --git a/test/Helper/UrlIntegrationTest.php b/test/Helper/UrlIntegrationTest.php index 0cecc4413..ceed21878 100644 --- a/test/Helper/UrlIntegrationTest.php +++ b/test/Helper/UrlIntegrationTest.php @@ -4,8 +4,6 @@ namespace LaminasTest\View\Helper; -use Laminas\Console\Console; -use Laminas\Console\Request as ConsoleRequest; use Laminas\Http\Request as HttpRequest; use Laminas\Mvc\Service\ServiceListenerFactory; use Laminas\Mvc\Service\ServiceManagerConfig; @@ -73,7 +71,6 @@ protected function setUp(): void public function testUrlHelperWorksUnderNormalHttpParadigms(): void { - Console::overrideIsConsole(false); $this->serviceManager->get('Application')->bootstrap(); $request = $this->serviceManager->get('Request'); $this->assertInstanceOf(HttpRequest::class, $request); @@ -85,7 +82,6 @@ public function testUrlHelperWorksUnderNormalHttpParadigms(): void public function testUrlHelperWorksWithForceCanonicalFlag(): void { - Console::overrideIsConsole(false); $this->serviceManager->get('Application')->bootstrap(); $request = $this->serviceManager->get('Request'); $this->assertInstanceOf(HttpRequest::class, $request); @@ -97,18 +93,4 @@ public function testUrlHelperWorksWithForceCanonicalFlag(): void $test = $urlHelper('test', [], ['force_canonical' => true]); $this->assertStringContainsString('/test', $test); } - - public function testUrlHelperUnderConsoleParadigmShouldReturnHttpRoutes(): void - { - Console::overrideIsConsole(true); - $this->serviceManager->setAllowOverride(true); - $this->serviceManager->setService('Request', new ConsoleRequest()); - $this->serviceManager->get('Application')->bootstrap(); - $request = $this->serviceManager->get('Request'); - $this->assertInstanceOf(ConsoleRequest::class, $request); - $viewHelpers = $this->serviceManager->get('ViewHelperManager'); - $urlHelper = $viewHelpers->get('url'); - $test = $urlHelper('test'); - $this->assertEquals('/test', $test); - } } diff --git a/test/Model/ConsoleModelTest.php b/test/Model/ConsoleModelTest.php deleted file mode 100644 index 0d38876f4..000000000 --- a/test/Model/ConsoleModelTest.php +++ /dev/null @@ -1,30 +0,0 @@ -assertInstanceOf(ModelInterface::class, $model); - } - - /** - * @see https://github.com/zendframework/zend-view/issues/152 - */ - public function testSetErrorLevelImplementsFluentInterface(): void - { - /** @psalm-suppress DeprecatedClass */ - $model = new ConsoleModel(); - $actual = $model->setErrorLevel(0); - $this->assertSame($model, $actual); - } -} From c9b36df402c5af2f237129c569ea5991d5442b58 Mon Sep 17 00:00:00 2001 From: George Steel Date: Wed, 23 Mar 2022 14:40:15 +0000 Subject: [PATCH 12/58] Lock file rebase Signed-off-by: George Steel --- composer.lock | 130 +------------------------------------------------- 1 file changed, 1 insertion(+), 129 deletions(-) diff --git a/composer.lock b/composer.lock index d93be8639..082c1ac39 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "adb0342243aa19eb2796daf3fd170b5a", + "content-hash": "0f00486d475406252bb25572f2c9a2d3", "packages": [ { "name": "container-interop/container-interop", @@ -1406,72 +1406,6 @@ ], "time": "2021-10-01T16:07:46+00:00" }, - { - "name": "laminas/laminas-console", - "version": "2.8.0", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-console.git", - "reference": "478a6ceac3e31fb38d6314088abda8b239ee23a5" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-console/zipball/478a6ceac3e31fb38d6314088abda8b239ee23a5", - "reference": "478a6ceac3e31fb38d6314088abda8b239ee23a5", - "shasum": "" - }, - "require": { - "laminas/laminas-stdlib": "^3.2.1", - "laminas/laminas-zendframework-bridge": "^1.0", - "php": "^5.6 || ^7.0" - }, - "replace": { - "zendframework/zend-console": "self.version" - }, - "require-dev": { - "laminas/laminas-coding-standard": "~1.0.0", - "laminas/laminas-filter": "^2.7.2", - "laminas/laminas-json": "^2.6 || ^3.0", - "laminas/laminas-validator": "^2.10.1", - "phpunit/phpunit": "^5.7.23 || ^6.4.3" - }, - "suggest": { - "laminas/laminas-filter": "To support DefaultRouteMatcher usage", - "laminas/laminas-validator": "To support DefaultRouteMatcher usage" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.8.x-dev", - "dev-develop": "2.9.x-dev" - } - }, - "autoload": { - "psr-4": { - "Laminas\\Console\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Build console applications using getopt syntax or routing, complete with prompts", - "homepage": "https://laminas.dev", - "keywords": [ - "console", - "laminas" - ], - "support": { - "chat": "https://laminas.dev/chat", - "docs": "https://docs.laminas.dev/laminas-console/", - "forum": "https://discourse.laminas.dev", - "issues": "https://github.com/laminas/laminas-console/issues", - "rss": "https://github.com/laminas/laminas-console/releases.atom", - "source": "https://github.com/laminas/laminas-console" - }, - "abandoned": "laminas/laminas-cli", - "time": "2019-12-31T16:31:45+00:00" - }, { "name": "laminas/laminas-feed", "version": "2.16.0", @@ -2658,68 +2592,6 @@ ], "time": "2022-03-08T18:16:51+00:00" }, - { - "name": "laminas/laminas-zendframework-bridge", - "version": "1.5.0", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-zendframework-bridge.git", - "reference": "7f049390b756d34ba5940a8fb47634fbb51f79ab" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-zendframework-bridge/zipball/7f049390b756d34ba5940a8fb47634fbb51f79ab", - "reference": "7f049390b756d34ba5940a8fb47634fbb51f79ab", - "shasum": "" - }, - "require": { - "php": ">=7.4, <8.2" - }, - "require-dev": { - "phpunit/phpunit": "^9.5.14", - "psalm/plugin-phpunit": "^0.15.2", - "squizlabs/php_codesniffer": "^3.6.2", - "vimeo/psalm": "^4.21.0" - }, - "type": "library", - "extra": { - "laminas": { - "module": "Laminas\\ZendFrameworkBridge" - } - }, - "autoload": { - "files": [ - "src/autoload.php" - ], - "psr-4": { - "Laminas\\ZendFrameworkBridge\\": "src//" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Alias legacy ZF class names to Laminas Project equivalents.", - "keywords": [ - "ZendFramework", - "autoloading", - "laminas", - "zf" - ], - "support": { - "forum": "https://discourse.laminas.dev/", - "issues": "https://github.com/laminas/laminas-zendframework-bridge/issues", - "rss": "https://github.com/laminas/laminas-zendframework-bridge/releases.atom", - "source": "https://github.com/laminas/laminas-zendframework-bridge" - }, - "funding": [ - { - "url": "https://funding.communitybridge.org/projects/laminas-project", - "type": "community_bridge" - } - ], - "time": "2022-02-22T22:17:01+00:00" - }, { "name": "myclabs/deep-copy", "version": "1.11.0", From 7bdb2f7ec101f61c59caf7d41210677bb0a5a685 Mon Sep 17 00:00:00 2001 From: Abdul Malik Ikhsan Date: Tue, 14 Jul 2020 15:27:25 +0700 Subject: [PATCH 13/58] Fixes #16 remove FlashMessenger view helper Signed-off-by: Abdul Malik Ikhsan --- docs/book/helpers/flash-messenger.md | 146 ----- docs/book/helpers/intro.md | 7 +- src/Helper/FlashMessenger.php | 354 ----------- src/Helper/Service/FlashMessengerFactory.php | 57 -- src/HelperPluginManager.php | 4 - src/Renderer/PhpRenderer.php | 1 - test/Helper/FlashMessengerTest.php | 558 ------------------ test/HelperPluginManagerCompatibilityTest.php | 10 +- 8 files changed, 7 insertions(+), 1130 deletions(-) delete mode 100644 docs/book/helpers/flash-messenger.md delete mode 100644 src/Helper/FlashMessenger.php delete mode 100644 src/Helper/Service/FlashMessengerFactory.php delete mode 100644 test/Helper/FlashMessengerTest.php diff --git a/docs/book/helpers/flash-messenger.md b/docs/book/helpers/flash-messenger.md deleted file mode 100644 index 95a21fb99..000000000 --- a/docs/book/helpers/flash-messenger.md +++ /dev/null @@ -1,146 +0,0 @@ -# FlashMessenger - -The `FlashMessenger` helper is used to render the messages of the -[FlashMessenger MVC plugin](https://docs.laminas.dev/laminas-mvc-plugin-flashmessenger/). - -## Basic Usage - -When only using the default `namespace` for the `FlashMessenger`, you can do the -following: - -```php -// Usable in any of your .phtml files -echo $this->flashMessenger()->render(); -``` - -The first argument of the `render()` function is the `namespace`. If no -`namespace` is defined, the default -`Laminas\Mvc\Controller\Plugin\FlashMessenger::NAMESPACE_DEFAULT` will be used, -which translates to `default`. - -```php -// Usable in any of your .phtml files -echo $this->flashMessenger()->render('error'); - -// Alternatively use one of the pre-defined namespaces -// (aka: use Laminas\Mvc\Controller\Plugin\FlashMessenger;) -echo $this->flashMessenger()->render(FlashMessenger::NAMESPACE_SUCCESS); -``` - -## CSS Layout - -The `FlashMessenger` default rendering adds a CSS class to the generated HTML, -that matches the defined `namespace` that should be rendered. While it may work -well for the default cases, every so often you may want to add specific CSS -classes to the HTML output. This can be done while making use of the second -parameter of the `render()` function. - -```php -// Usable in any of your .phtml files -echo $this->flashMessenger()->render('error', ['alert', 'alert-danger']); -``` - -The output of this example, using the default HTML rendering settings, would -look like this: - -```html -
    -
  • Some FlashMessenger Content
  • -
  • You, the developer, are AWESOME!
  • -
-``` - -## HTML Layout - -Aside from modifying the rendered CSS classes of the `FlashMessenger`, you are -furthermore able to modify the generated HTML as a whole to create even more -distinct visuals for your flash messages. The default output format is defined -within the source code of the `FlashMessenger` view helper itself. - -```php -// Laminas/View/Helper/FlashMessenger.php#L41-L43 -protected $messageCloseString = ''; -protected $messageOpenFormat = '
  • '; -protected $messageSeparatorString = '
  • '; -``` - -These defaults exactly match what we're trying to do. The placeholder `%s` will -be filled with the CSS classes output. - -To change this, all we need to do is call the respective setter methods of these -variables and give them new strings; for example: - -```php -// In any of your .phtml files: -echo $this->flashMessenger() - ->setMessageOpenFormat('

    ') - ->setMessageSeparatorString('

    ') - ->setMessageCloseString('

    ') - ->render('success'); -``` - -The above code sample then would then generate the following output: - -```html -
    -

    Some FlashMessenger Content

    -

    You, who's reading the docs, are AWESOME!

    -
    -``` - -## Sample Modification for Twitter Bootstrap 3 - -Taking all the above knowledge into account, we can create a nice, highly usable -and user-friendly rendering strategy using the -[Bootstrap front-end framework](http://getbootstrap.com/) version 3 layouts: - -```php -// In any of your .phtml files: -$flash = $this->flashMessenger(); -$flash->setMessageOpenFormat(' - -
    • ') - ->setMessageSeparatorString('
    • ') - ->setMessageCloseString('
    '); - -echo $flash->render('error', ['alert', 'alert-dismissible', 'alert-danger']); -echo $flash->render('info', ['alert', 'alert-dismissible', 'alert-info']); -echo $flash->render('default', ['alert', 'alert-dismissible', 'alert-warning']); -echo $flash->render('success', ['alert', 'alert-dismissible', 'alert-success']); -``` - -The output of the above example would create dismissable `FlashMessages` with -the following HTML markup. The example only covers one type of `FlashMessenger` -output; if you would have several `FlashMessages` available in each of the -rendered `namespaces`, then you would receive the same output multiple times -only having different CSS classes applied. - -```html -
    - -
      -
    • Some FlashMessenger Content
    • -
    • You, who's reading the docs, are AWESOME!
    • -
    -
    -``` - -## Alternative Configuration of the ViewHelper Layout - -`Laminas\View\Helper\Service\FlashMessengerFactory` checks the application -configuration, making it possible to set up the `FlashMessenger` strings through -your `module.config.php`, too. The next example will set up the output to be -identical with the above Twitter Bootstrap 3 Example - -```php -'view_helper_config' => [ - 'flashmessenger' => [ - 'message_open_format' => '
    • ', - 'message_close_string' => '
    ', - 'message_separator_string' => '
  • ', - ], -], -``` diff --git a/docs/book/helpers/intro.md b/docs/book/helpers/intro.md index 5402f9774..699f9f8c7 100644 --- a/docs/book/helpers/intro.md +++ b/docs/book/helpers/intro.md @@ -60,7 +60,6 @@ for, and rendering, the various HTML `` tags, such as `HeadTitle`, - [BasePath](base-path.md) - [Cycle](cycle.md) - [Doctype](doctype.md) -- [FlashMessenger](flash-messenger.md) - [Gravatar](gravatar.md) - [HeadLink](head-link.md) - [HeadMeta](head-meta.md) @@ -109,6 +108,12 @@ for, and rendering, the various HTML `` tags, such as `HeadTitle`, > [Paginator Usage](https://docs.laminas.dev/laminas-paginator/usage/#rendering-pages-with-view-scripts) > documentation. +> ### FlashMessenger helper +> +> View helper related to **Flash Messenger** is documented in the +> [FLash Messenger View Helper](https://docs.laminas.dev/laminas-mvc-plugin-flashmessenger/view-helper/) +> documentation. + > ### Custom Helpers > > For documentation on writing **custom view helpers** see the diff --git a/src/Helper/FlashMessenger.php b/src/Helper/FlashMessenger.php deleted file mode 100644 index 8e12f5cd7..000000000 --- a/src/Helper/FlashMessenger.php +++ /dev/null @@ -1,354 +0,0 @@ - 'info', - 'error' => 'error', - 'success' => 'success', - 'default' => 'default', - 'warning' => 'warning', - ]; - - /** - * Templates for the open/close/separators for message tags - * - * @var string - */ - protected $messageCloseString = '
  • '; - /** @var string */ - protected $messageOpenFormat = '
  • '; - /** @var string */ - protected $messageSeparatorString = '
  • '; - - /** - * Flag whether to escape messages - * - * @var bool - */ - protected $autoEscape = true; - - /** - * Html escape helper - * - * @var EscapeHtml - */ - protected $escapeHtmlHelper; - - /** - * Flash messenger plugin - * - * @var PluginFlashMessenger - */ - protected $pluginFlashMessenger; - - /** - * Returns the flash messenger plugin controller - * - * @param string|null $namespace - * @return array|static - */ - public function __invoke($namespace = null) - { - if (null === $namespace) { - return $this; - } - $flashMessenger = $this->getPluginFlashMessenger(); - - return $flashMessenger->getMessagesFromNamespace($namespace); - } - - /** - * Proxy the flash messenger plugin controller - * - * @param string $method - * @param array $argv - * @return mixed - */ - public function __call($method, $argv) - { - $flashMessenger = $this->getPluginFlashMessenger(); - return call_user_func_array([$flashMessenger, $method], $argv); - } - - /** - * Render Messages - * - * @param string $namespace - * @param array $classes - * @param null|bool $autoEscape - * @return string - */ - public function render($namespace = 'default', array $classes = [], $autoEscape = null) - { - $flashMessenger = $this->getPluginFlashMessenger(); - $messages = $flashMessenger->getMessagesFromNamespace($namespace); - return $this->renderMessages($namespace, $messages, $classes, $autoEscape); - } - - /** - * Render Current Messages - * - * @param string $namespace - * @param array $classes - * @param bool|null $autoEscape - * @return string - */ - public function renderCurrent($namespace = 'default', array $classes = [], $autoEscape = null) - { - $flashMessenger = $this->getPluginFlashMessenger(); - $messages = $flashMessenger->getCurrentMessagesFromNamespace($namespace); - return $this->renderMessages($namespace, $messages, $classes, $autoEscape); - } - - /** - * Render Messages - * - * @param string $namespace - * @param array $messages - * @param array $classes - * @param bool|null $autoEscape - * @return string - */ - protected function renderMessages( - $namespace = 'default', - array $messages = [], - array $classes = [], - $autoEscape = null - ) { - if (empty($messages)) { - return ''; - } - - // Prepare classes for opening tag - if (empty($classes)) { - if (isset($this->classMessages[$namespace])) { - $classes = $this->classMessages[$namespace]; - } else { - $classes = $this->classMessages['default']; - } - $classes = [$classes]; - } - - if (null === $autoEscape) { - $autoEscape = $this->getAutoEscape(); - } - - // Flatten message array - $escapeHtml = $this->getEscapeHtmlHelper(); - $messagesToPrint = []; - $translator = $this->getTranslator(); - $translatorTextDomain = $this->getTranslatorTextDomain(); - array_walk_recursive( - $messages, - function ($item) use (&$messagesToPrint, $escapeHtml, $autoEscape, $translator, $translatorTextDomain) { - if ($translator !== null) { - $item = $translator->translate( - $item, - $translatorTextDomain - ); - } - - if ($autoEscape) { - $messagesToPrint[] = $escapeHtml($item); - return; - } - - $messagesToPrint[] = $item; - } - ); - - if (empty($messagesToPrint)) { - return ''; - } - - // Generate markup - $markup = sprintf($this->getMessageOpenFormat(), ' class="' . implode(' ', $classes) . '"'); - $markup .= implode( - sprintf($this->getMessageSeparatorString(), ' class="' . implode(' ', $classes) . '"'), - $messagesToPrint - ); - $markup .= $this->getMessageCloseString(); - return $markup; - } - - /** - * Set whether or not auto escaping should be used - * - * @param bool $autoEscape - * @return self - */ - public function setAutoEscape($autoEscape = true) - { - $this->autoEscape = (bool) $autoEscape; - return $this; - } - - /** - * Return whether auto escaping is enabled or disabled - * - * @return bool - */ - public function getAutoEscape() - { - return $this->autoEscape; - } - - /** - * Set the string used to close message representation - * - * @param string $messageCloseString - * @return FlashMessenger - */ - public function setMessageCloseString($messageCloseString) - { - $this->messageCloseString = (string) $messageCloseString; - return $this; - } - - /** - * Get the string used to close message representation - * - * @return string - */ - public function getMessageCloseString() - { - return $this->messageCloseString; - } - - /** - * Set the formatted string used to open message representation - * - * @param string $messageOpenFormat - * @return FlashMessenger - */ - public function setMessageOpenFormat($messageOpenFormat) - { - $this->messageOpenFormat = (string) $messageOpenFormat; - return $this; - } - - /** - * Get the formatted string used to open message representation - * - * @return string - */ - public function getMessageOpenFormat() - { - return $this->messageOpenFormat; - } - - /** - * Set the string used to separate messages - * - * @param string $messageSeparatorString - * @return FlashMessenger - */ - public function setMessageSeparatorString($messageSeparatorString) - { - $this->messageSeparatorString = (string) $messageSeparatorString; - return $this; - } - - /** - * Get the string used to separate messages - * - * @return string - */ - public function getMessageSeparatorString() - { - return $this->messageSeparatorString; - } - - /** - * Set the flash messenger plugin - * - * @param PluginFlashMessenger $pluginFlashMessenger - * @return FlashMessenger - * @throws InvalidArgumentException For an invalid $pluginFlashMessenger. - * @psalm-suppress RedundantConditionGivenDocblockType, DocblockTypeContradiction - */ - public function setPluginFlashMessenger($pluginFlashMessenger) - { - if (! $pluginFlashMessenger instanceof PluginFlashMessenger) { - throw new InvalidArgumentException(sprintf( - '%s expects a %s instance; received %s', - __METHOD__, - PluginFlashMessenger::class, - is_object($pluginFlashMessenger) ? get_class($pluginFlashMessenger) : gettype($pluginFlashMessenger) - )); - } - - $this->pluginFlashMessenger = $pluginFlashMessenger; - return $this; - } - - /** - * Get the flash messenger plugin - * - * @return PluginFlashMessenger - */ - public function getPluginFlashMessenger() - { - if (null === $this->pluginFlashMessenger) { - $this->setPluginFlashMessenger(new PluginFlashMessenger()); - } - - return $this->pluginFlashMessenger; - } - - /** - * Retrieve the escapeHtml helper - * - * @return EscapeHtml - */ - protected function getEscapeHtmlHelper() - { - if ($this->escapeHtmlHelper) { - return $this->escapeHtmlHelper; - } - - if (null !== $this->view && method_exists($this->view, 'plugin')) { - $this->escapeHtmlHelper = $this->view->plugin('escapehtml'); - } - - if (! $this->escapeHtmlHelper instanceof EscapeHtml) { - $this->escapeHtmlHelper = new EscapeHtml(); - } - - return $this->escapeHtmlHelper; - } -} diff --git a/src/Helper/Service/FlashMessengerFactory.php b/src/Helper/Service/FlashMessengerFactory.php deleted file mode 100644 index 8d605efdf..000000000 --- a/src/Helper/Service/FlashMessengerFactory.php +++ /dev/null @@ -1,57 +0,0 @@ -get('ControllerPluginManager'); - $flashMessenger = $controllerPluginManager->get('flashmessenger'); - - $helper->setPluginFlashMessenger($flashMessenger); - - $config = $container->get('config'); - if (isset($config['view_helper_config']['flashmessenger'])) { - $configHelper = $config['view_helper_config']['flashmessenger']; - if (isset($configHelper['message_open_format'])) { - $helper->setMessageOpenFormat($configHelper['message_open_format']); - } - if (isset($configHelper['message_separator_string'])) { - $helper->setMessageSeparatorString($configHelper['message_separator_string']); - } - if (isset($configHelper['message_close_string'])) { - $helper->setMessageCloseString($configHelper['message_close_string']); - } - } - - return $helper; - } - - /** - * Create service (v2) - * - * @param string $normalizedName - * @param string $requestedName - * @return FlashMessenger - */ - public function createService(ServiceLocatorInterface $container, $normalizedName = null, $requestedName = null) - { - return $this($container, $requestedName); - } -} diff --git a/src/HelperPluginManager.php b/src/HelperPluginManager.php index 775d1e560..f5cc770bd 100644 --- a/src/HelperPluginManager.php +++ b/src/HelperPluginManager.php @@ -71,9 +71,6 @@ class HelperPluginManager extends AbstractPluginManager 'escapeUrl' => Helper\EscapeUrl::class, 'EscapeUrl' => Helper\EscapeUrl::class, 'escapeurl' => Helper\EscapeUrl::class, - 'flashmessenger' => Helper\FlashMessenger::class, - 'flashMessenger' => Helper\FlashMessenger::class, - 'FlashMessenger' => Helper\FlashMessenger::class, 'Gravatar' => Helper\Gravatar::class, 'gravatar' => Helper\Gravatar::class, 'headLink' => Helper\HeadLink::class, @@ -158,7 +155,6 @@ class HelperPluginManager extends AbstractPluginManager protected $factories = [ Helper\Asset::class => Helper\Service\AssetFactory::class, Helper\HtmlAttributes::class => InvokableFactory::class, - Helper\FlashMessenger::class => Helper\Service\FlashMessengerFactory::class, Helper\Identity::class => Helper\Service\IdentityFactory::class, Helper\BasePath::class => InvokableFactory::class, Helper\Cycle::class => InvokableFactory::class, diff --git a/src/Renderer/PhpRenderer.php b/src/Renderer/PhpRenderer.php index 7e3aeee47..6f55baa73 100644 --- a/src/Renderer/PhpRenderer.php +++ b/src/Renderer/PhpRenderer.php @@ -55,7 +55,6 @@ * @method mixed escapeHtmlAttr($value, $recurse = \Laminas\View\Helper\Escaper\AbstractHelper::RECURSE_NONE) * @method mixed escapeJs($value, $recurse = \Laminas\View\Helper\Escaper\AbstractHelper::RECURSE_NONE) * @method mixed escapeUrl($value, $recurse = \Laminas\View\Helper\Escaper\AbstractHelper::RECURSE_NONE) - * @method \Laminas\View\Helper\FlashMessenger flashMessenger($namespace = null) * @method \Laminas\View\Helper\Gravatar gravatar($email = "", $options = array(), $attribs = array()) * @method \Laminas\View\Helper\HeadLink headLink(array $attributes = null, $placement = \Laminas\View\Helper\Placeholder\Container\AbstractContainer::APPEND) * @method \Laminas\View\Helper\HeadMeta headMeta($content = null, $keyValue = null, $keyType = 'name', $modifiers = array(), $placement = \Laminas\View\Helper\Placeholder\Container\AbstractContainer::APPEND) diff --git a/test/Helper/FlashMessengerTest.php b/test/Helper/FlashMessengerTest.php deleted file mode 100644 index 11ff5c401..000000000 --- a/test/Helper/FlashMessengerTest.php +++ /dev/null @@ -1,558 +0,0 @@ -mvcPluginClass = V3PluginFlashMessenger::class; - /** @psalm-suppress DeprecatedClass */ - $this->helper = new FlashMessenger(); - $this->plugin = $this->helper->getPluginFlashMessenger(); - } - - public function seedMessages(): void - { - /** @psalm-suppress DeprecatedClass */ - $helper = new FlashMessenger(); - $helper->addMessage('foo'); - $helper->addMessage('bar'); - $helper->addInfoMessage('bar-info'); - $helper->addSuccessMessage('bar-success'); - $helper->addWarningMessage('bar-warning'); - $helper->addErrorMessage('bar-error'); - unset($helper); - } - - public function seedCurrentMessages(): void - { - /** @psalm-suppress DeprecatedClass */ - $helper = new FlashMessenger(); - $helper->addMessage('foo'); - $helper->addMessage('bar'); - $helper->addInfoMessage('bar-info'); - $helper->addSuccessMessage('bar-success'); - $helper->addErrorMessage('bar-error'); - } - - public function createServiceManager(array $config = []): ServiceManager - { - $config = new Config([ - 'services' => [ - 'config' => $config, - ], - 'factories' => [ - 'ControllerPluginManager' => fn(ContainerInterface $services) => new PluginManager($services, [ - 'invokables' => [ - 'flashmessenger' => $this->mvcPluginClass, - ], - ]), - 'ViewHelperManager' => static fn(ContainerInterface $services) - => new HelperPluginManager($services), - ], - ]); - $sm = new ServiceManager(); - $config->configureServiceManager($sm); - return $sm; - } - - public function testCanAssertPluginClass(): void - { - $this->assertEquals($this->mvcPluginClass, get_class($this->plugin)); - $this->assertEquals($this->mvcPluginClass, get_class($this->helper->getPluginFlashMessenger())); - $this->assertSame($this->plugin, $this->helper->getPluginFlashMessenger()); - } - - public function testCanRetrieveMessages(): void - { - $helper = $this->helper; - - $this->assertFalse($helper()->hasMessages()); - $this->assertFalse($helper()->hasInfoMessages()); - $this->assertFalse($helper()->hasSuccessMessages()); - $this->assertFalse($helper()->hasWarningMessages()); - $this->assertFalse($helper()->hasErrorMessages()); - - $this->seedMessages(); - - $this->assertNotEmpty($helper('default')); - $this->assertNotEmpty($helper('info')); - $this->assertNotEmpty($helper('success')); - $this->assertNotEmpty($helper('warning')); - $this->assertNotEmpty($helper('error')); - - $this->assertTrue($this->plugin->hasMessages()); - $this->assertTrue($this->plugin->hasInfoMessages()); - $this->assertTrue($this->plugin->hasSuccessMessages()); - $this->assertTrue($this->plugin->hasWarningMessages()); - $this->assertTrue($this->plugin->hasErrorMessages()); - } - - public function testCanRetrieveCurrentMessages(): void - { - $helper = $this->helper; - - $this->assertFalse($helper()->hasCurrentMessages()); - $this->assertFalse($helper()->hasCurrentInfoMessages()); - $this->assertFalse($helper()->hasCurrentSuccessMessages()); - $this->assertFalse($helper()->hasCurrentErrorMessages()); - - $this->seedCurrentMessages(); - - $this->assertNotEmpty($helper('default')); - $this->assertNotEmpty($helper('info')); - $this->assertNotEmpty($helper('success')); - $this->assertNotEmpty($helper('error')); - - $this->assertFalse($this->plugin->hasCurrentMessages()); - $this->assertFalse($this->plugin->hasCurrentInfoMessages()); - $this->assertFalse($this->plugin->hasCurrentSuccessMessages()); - $this->assertFalse($this->plugin->hasCurrentErrorMessages()); - } - - public function testCanProxyAndRetrieveMessagesFromPluginController(): void - { - $this->assertFalse($this->helper->hasMessages()); - $this->assertFalse($this->helper->hasInfoMessages()); - $this->assertFalse($this->helper->hasSuccessMessages()); - $this->assertFalse($this->helper->hasWarningMessages()); - $this->assertFalse($this->helper->hasErrorMessages()); - - $this->seedMessages(); - - $this->assertTrue($this->helper->hasMessages()); - $this->assertTrue($this->helper->hasInfoMessages()); - $this->assertTrue($this->helper->hasSuccessMessages()); - $this->assertTrue($this->helper->hasWarningMessages()); - $this->assertTrue($this->helper->hasErrorMessages()); - } - - public function testCanProxyAndRetrieveCurrentMessagesFromPluginController(): void - { - $this->assertFalse($this->helper->hasCurrentMessages()); - $this->assertFalse($this->helper->hasCurrentInfoMessages()); - $this->assertFalse($this->helper->hasCurrentSuccessMessages()); - $this->assertFalse($this->helper->hasCurrentErrorMessages()); - - $this->seedCurrentMessages(); - - $this->assertTrue($this->helper->hasCurrentMessages()); - $this->assertTrue($this->helper->hasCurrentInfoMessages()); - $this->assertTrue($this->helper->hasCurrentSuccessMessages()); - $this->assertTrue($this->helper->hasCurrentErrorMessages()); - } - - public function testCanDisplayListOfMessages(): void - { - $plugin = $this->prophesize($this->mvcPluginClass); - $plugin->getMessagesFromNamespace('info')->will(fn() => []); - $plugin->addInfoMessage('bar-info')->will(function ($args) { - $this->getMessagesFromNamespace('info')->willReturn([$args[0]]); - return null; - }); - - $this->helper->setPluginFlashMessenger($plugin->reveal()); - - $displayInfoAssertion = ''; - $displayInfo = $this->helper->render('info'); - $this->assertEquals($displayInfoAssertion, $displayInfo); - - $helper = new FlashMessenger(); - $helper->setPluginFlashMessenger($plugin->reveal()); - $helper->addInfoMessage('bar-info'); - unset($helper); - - $displayInfoAssertion = '
    • bar-info
    '; - $displayInfo = $this->helper->render('info'); - $this->assertEquals($displayInfoAssertion, $displayInfo); - } - - /** - * @runInSeparateProcess - * @preserveGlobalState disabled - */ - public function testCanDisplayListOfCurrentMessages(): void - { - $displayInfoAssertion = ''; - $displayInfo = $this->helper->renderCurrent('info'); - $this->assertEquals($displayInfoAssertion, $displayInfo); - - $this->seedCurrentMessages(); - - $displayInfoAssertion = '
    • bar-info
    '; - $displayInfo = $this->helper->renderCurrent('info'); - $this->assertEquals($displayInfoAssertion, $displayInfo); - } - - public function testCanDisplayListOfMessagesByDefaultParameters(): void - { - $helper = $this->helper; - $this->seedMessages(); - - $displayInfoAssertion = '
    • foo
    • bar
    '; - $displayInfo = $helper()->render(); - $this->assertEquals($displayInfoAssertion, $displayInfo); - } - - public function testCanDisplayListOfMessagesByDefaultCurrentParameters(): void - { - $helper = $this->helper; - $this->seedCurrentMessages(); - - $displayInfoAssertion = '
    • foo
    • bar
    '; - $displayInfo = $helper()->renderCurrent(); - $this->assertEquals($displayInfoAssertion, $displayInfo); - } - - public function testCanDisplayListOfMessagesByInvoke(): void - { - $helper = $this->helper; - $this->seedMessages(); - - $displayInfoAssertion = '
    • bar-info
    '; - $displayInfo = $helper()->render('info'); - $this->assertEquals($displayInfoAssertion, $displayInfo); - } - - public function testCanDisplayListOfCurrentMessagesByInvoke(): void - { - $helper = $this->helper; - $this->seedCurrentMessages(); - - $displayInfoAssertion = '
    • bar-info
    '; - $displayInfo = $helper()->renderCurrent('info'); - $this->assertEquals($displayInfoAssertion, $displayInfo); - } - - public function testCanDisplayListOfMessagesCustomised(): void - { - $this->seedMessages(); - - $displayInfoAssertion = '

    bar-info

    '; - $displayInfo = $this->helper - ->setMessageOpenFormat('

    ') - ->setMessageSeparatorString('

    ') - ->setMessageCloseString('

    ') - ->render('info', ['foo-baz', 'foo-bar']); - $this->assertEquals($displayInfoAssertion, $displayInfo); - } - - public function testCanDisplayListOfCurrentMessagesCustomised(): void - { - $this->seedCurrentMessages(); - - $displayInfoAssertion = '

    bar-info

    '; - $displayInfo = $this->helper - ->setMessageOpenFormat('

    ') - ->setMessageSeparatorString('

    ') - ->setMessageCloseString('

    ') - ->renderCurrent('info', ['foo-baz', 'foo-bar']); - $this->assertEquals($displayInfoAssertion, $displayInfo); - } - - public function testCanDisplayListOfMessagesCustomisedSeparator(): void - { - $this->seedMessages(); - - $displayInfoAssertion = '

    foo

    bar

    '; - $displayInfo = $this->helper - ->setMessageOpenFormat('
    ') - ->setMessageSeparatorString('

    ') - ->setMessageCloseString('

    ') - ->render('default', ['foo-baz', 'foo-bar']); - $this->assertEquals($displayInfoAssertion, $displayInfo); - } - - public function testCanDisplayListOfCurrentMessagesCustomisedSeparator(): void - { - $this->seedCurrentMessages(); - - $displayInfoAssertion = '

    foo

    bar

    '; - $displayInfo = $this->helper - ->setMessageOpenFormat('
    ') - ->setMessageSeparatorString('

    ') - ->setMessageCloseString('

    ') - ->renderCurrent('default', ['foo-baz', 'foo-bar']); - $this->assertEquals($displayInfoAssertion, $displayInfo); - } - - public function testCanDisplayListOfMessagesCustomisedByConfig(): void - { - $this->seedMessages(); - - $config = [ - 'view_helper_config' => [ - 'flashmessenger' => [ - 'message_open_format' => '
    • ', - 'message_separator_string' => '
    • ', - 'message_close_string' => '
    ', - ], - ], - ]; - - $services = $this->createServiceManager($config); - $helperPluginManager = $services->get('ViewHelperManager'); - $helper = $helperPluginManager->get('flashmessenger'); - - $displayInfoAssertion = '
    • bar-info
    '; - $displayInfo = $helper->render('info'); - $this->assertEquals($displayInfoAssertion, $displayInfo); - } - - public function testCanDisplayListOfCurrentMessagesCustomisedByConfig(): void - { - $this->seedCurrentMessages(); - $config = [ - 'view_helper_config' => [ - 'flashmessenger' => [ - 'message_open_format' => '
    • ', - 'message_separator_string' => '
    • ', - 'message_close_string' => '
    ', - ], - ], - ]; - $services = $this->createServiceManager($config); - $helperPluginManager = $services->get('ViewHelperManager'); - $helper = $helperPluginManager->get('flashmessenger'); - - $displayInfoAssertion = '
    • bar-info
    '; - $displayInfo = $helper->renderCurrent('info'); - $this->assertEquals($displayInfoAssertion, $displayInfo); - } - - public function testCanDisplayListOfMessagesCustomisedByConfigSeparator(): void - { - $this->seedMessages(); - - $config = [ - 'view_helper_config' => [ - 'flashmessenger' => [ - 'message_open_format' => '
      ', - 'message_separator_string' => '', - 'message_close_string' => '
    ', - ], - ], - ]; - $services = $this->createServiceManager($config); - $helperPluginManager = $services->get('ViewHelperManager'); - $helper = $helperPluginManager->get('flashmessenger'); - - // @codingStandardsIgnoreStart - $displayInfoAssertion = '
    • foo
    • bar
    '; - // @codingStandardsIgnoreEnd - $displayInfo = $helper->render('default', ['foo-baz', 'foo-bar']); - $this->assertEquals($displayInfoAssertion, $displayInfo); - } - - public function testCanDisplayListOfCurrentMessagesCustomisedByConfigSeparator(): void - { - $this->seedCurrentMessages(); - - $config = [ - 'view_helper_config' => [ - 'flashmessenger' => [ - 'message_open_format' => '
      ', - 'message_separator_string' => '', - 'message_close_string' => '
    ', - ], - ], - ]; - $services = $this->createServiceManager($config); - $helperPluginManager = $services->get('ViewHelperManager'); - $helper = $helperPluginManager->get('flashmessenger'); - - // @codingStandardsIgnoreStart - $displayInfoAssertion = '
    • foo
    • bar
    '; - // @codingStandardsIgnoreEnd - $displayInfo = $helper->renderCurrent('default', ['foo-baz', 'foo-bar']); - $this->assertEquals($displayInfoAssertion, $displayInfo); - } - - public function testCanTranslateMessages(): void - { - $mockTranslator = $this->prophesize(Translator::class); - $mockTranslator->translate('bar-info', 'default')->willReturn('translated message')->shouldBeCalledTimes(1); - - $this->helper->setTranslator($mockTranslator->reveal()); - $this->assertTrue($this->helper->hasTranslator()); - - $this->seedMessages(); - - $displayAssertion = '
    • translated message
    '; - $display = $this->helper->render('info'); - $this->assertEquals($displayAssertion, $display); - } - - public function testCanTranslateCurrentMessages(): void - { - $mockTranslator = $this->prophesize(Translator::class); - $mockTranslator->translate('bar-info', 'default')->willReturn('translated message')->shouldBeCalledTimes(1); - - $this->helper->setTranslator($mockTranslator->reveal()); - $this->assertTrue($this->helper->hasTranslator()); - - $this->seedCurrentMessages(); - - $displayAssertion = '
    • translated message
    '; - $display = $this->helper->renderCurrent('info'); - $this->assertEquals($displayAssertion, $display); - } - - public function testAutoEscapeDefaultsToTrue(): void - { - $this->assertTrue($this->helper->getAutoEscape()); - } - - public function testCanSetAutoEscape(): void - { - $this->helper->setAutoEscape(false); - $this->assertFalse($this->helper->getAutoEscape()); - - $this->helper->setAutoEscape(true); - $this->assertTrue($this->helper->getAutoEscape()); - } - - /** - * @covers \Laminas\View\Helper\FlashMessenger::render - */ - public function testMessageIsEscapedByDefault(): void - { - $helper = new FlashMessenger(); - $helper->addMessage('Foo
    bar'); - unset($helper); - - $displayAssertion = '
    • Foo<br />bar
    '; - $display = $this->helper->render('default'); - $this->assertSame($displayAssertion, $display); - } - - /** - * @covers \Laminas\View\Helper\FlashMessenger::render - */ - public function testMessageIsNotEscapedWhenAutoEscapeIsFalse(): void - { - $helper = new FlashMessenger(); - $helper->addMessage('Foo
    bar'); - unset($helper); - - $displayAssertion = '
    • Foo
      bar
    '; - $display = $this->helper->setAutoEscape(false) - ->render('default'); - $this->assertSame($displayAssertion, $display); - } - - /** - * @covers \Laminas\View\Helper\FlashMessenger::render - */ - public function testCanSetAutoEscapeOnRender(): void - { - $helper = new FlashMessenger(); - $helper->addMessage('Foo
    bar'); - unset($helper); - - $displayAssertion = '
    • Foo
      bar
    '; - $display = $this->helper->render('default', [], false); - $this->assertSame($displayAssertion, $display); - } - - /** - * @covers \Laminas\View\Helper\FlashMessenger::render - */ - public function testRenderUsesCurrentAutoEscapeByDefault(): void - { - $helper = new FlashMessenger(); - $helper->addMessage('Foo
    bar'); - unset($helper); - - $this->helper->setAutoEscape(false); - $displayAssertion = '
    • Foo
      bar
    '; - $display = $this->helper->render('default'); - $this->assertSame($displayAssertion, $display); - - $helper = new FlashMessenger(); - $helper->addMessage('Foo
    bar'); - unset($helper); - - $this->helper->setAutoEscape(true); - $displayAssertion = '
    • Foo<br />bar
    '; - $display = $this->helper->render('default'); - $this->assertSame($displayAssertion, $display); - } - - /** - * @covers \Laminas\View\Helper\FlashMessenger::renderCurrent - */ - public function testCurrentMessageIsEscapedByDefault(): void - { - $this->helper->addMessage('Foo
    bar'); - - $displayAssertion = '
    • Foo<br />bar
    '; - $display = $this->helper->renderCurrent('default'); - $this->assertSame($displayAssertion, $display); - } - - /** - * @covers \Laminas\View\Helper\FlashMessenger::renderCurrent - */ - public function testCurrentMessageIsNotEscapedWhenAutoEscapeIsFalse(): void - { - $this->helper->addMessage('Foo
    bar'); - - $displayAssertion = '
    • Foo
      bar
    '; - $display = $this->helper->setAutoEscape(false) - ->renderCurrent('default'); - $this->assertSame($displayAssertion, $display); - } - - /** - * @covers \Laminas\View\Helper\FlashMessenger::renderCurrent - */ - public function testCanSetAutoEscapeOnRenderCurrent(): void - { - $this->helper->addMessage('Foo
    bar'); - - $displayAssertion = '
    • Foo
      bar
    '; - $display = $this->helper->renderCurrent('default', [], false); - $this->assertSame($displayAssertion, $display); - } - - /** - * @covers \Laminas\View\Helper\FlashMessenger::renderCurrent - */ - public function testRenderCurrentUsesCurrentAutoEscapeByDefault(): void - { - $this->helper->addMessage('Foo
    bar'); - - $this->helper->setAutoEscape(false); - $displayAssertion = '
    • Foo
      bar
    '; - $display = $this->helper->renderCurrent('default'); - $this->assertSame($displayAssertion, $display); - - $this->helper->setAutoEscape(true); - $displayAssertion = '
    • Foo<br />bar
    '; - $display = $this->helper->renderCurrent('default'); - $this->assertSame($displayAssertion, $display); - } -} diff --git a/test/HelperPluginManagerCompatibilityTest.php b/test/HelperPluginManagerCompatibilityTest.php index 50ccba2e6..cdbb2fb67 100644 --- a/test/HelperPluginManagerCompatibilityTest.php +++ b/test/HelperPluginManagerCompatibilityTest.php @@ -6,7 +6,6 @@ use Generator; use Laminas\Mvc\Controller\PluginManager as ControllerPluginManager; -use Laminas\Mvc\Plugin\FlashMessenger\FlashMessenger; use Laminas\ServiceManager\Config; use Laminas\ServiceManager\ServiceManager; use Laminas\ServiceManager\Test\CommonPluginManagerTrait; @@ -30,9 +29,7 @@ protected function getPluginManager(): HelperPluginManager if (class_exists(ControllerPluginManager::class)) { // @codingStandardsIgnoreLine $factories['ControllerPluginManager'] = static fn(ContainerInterface $services): ControllerPluginManager => new ControllerPluginManager($services, [ - 'invokables' => [ - 'flashmessenger' => FlashMessenger::class, - ], + 'invokables' => [], ]); } @@ -63,11 +60,6 @@ public function aliasProvider(): Generator $aliases = $r->getValue($pluginManager); foreach ($aliases as $alias => $target) { - // Skipping conditionally since it depends on laminas-mvc - if (! class_exists(ControllerPluginManager::class) && strpos($target, '\\FlashMessenger')) { - continue; - } - // Skipping conditionally since it depends on laminas-mvc if (! class_exists(ControllerPluginManager::class) && strpos($target, '\\Url')) { continue; From e2fd333f7e22b35ef9e8d09c50baf3b5c6b200df Mon Sep 17 00:00:00 2001 From: George Steel Date: Tue, 1 Feb 2022 16:03:12 +0000 Subject: [PATCH 14/58] - Removes flash messenger from docs build - Removes magic method docs for removed helpers - Removes stray factory definition for removed helper Signed-off-by: George Steel --- mkdocs.yml | 1 - src/HelperPluginManager.php | 1 - src/Renderer/PhpRenderer.php | 2 -- 3 files changed, 4 deletions(-) diff --git a/mkdocs.yml b/mkdocs.yml index 2f7336948..f2ffae6e5 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -14,7 +14,6 @@ nav: - Cycle: helpers/cycle.md - Doctype: helpers/doctype.md - Escape: helpers/escape.md - - FlashMessenger: helpers/flash-messenger.md - Gravatar: helpers/gravatar.md - HeadLink: helpers/head-link.md - HeadMeta: helpers/head-meta.md diff --git a/src/HelperPluginManager.php b/src/HelperPluginManager.php index f5cc770bd..dbc541697 100644 --- a/src/HelperPluginManager.php +++ b/src/HelperPluginManager.php @@ -192,7 +192,6 @@ class HelperPluginManager extends AbstractPluginManager // v2 canonical FQCNs 'laminasviewhelperasset' => Helper\Service\AssetFactory::class, 'laminasviewhelperattributes' => InvokableFactory::class, - 'laminasviewhelperflashmessenger' => Helper\Service\FlashMessengerFactory::class, 'laminasviewhelperidentity' => Helper\Service\IdentityFactory::class, 'laminasviewhelperbasepath' => InvokableFactory::class, 'laminasviewhelpercycle' => InvokableFactory::class, diff --git a/src/Renderer/PhpRenderer.php b/src/Renderer/PhpRenderer.php index 6f55baa73..775d03a8b 100644 --- a/src/Renderer/PhpRenderer.php +++ b/src/Renderer/PhpRenderer.php @@ -62,11 +62,9 @@ * @method \Laminas\View\Helper\HeadStyle headStyle($content = null, $placement = 'APPEND', $attributes = array()) * @method \Laminas\View\Helper\HeadTitle headTitle($title = null, $setType = null) * @method \Laminas\View\HtmlAttributesSet htmlAttributes(iterable $attributes = []) - * @method string htmlFlash($data, array $attribs = array(), array $params = array(), $content = null) * @method string htmlList(array $items, $ordered = false, $attribs = false, $escape = true) * @method string htmlObject($data = null, $type = null, array $attribs = array(), array $params = array(), $content = null) * @method string htmlPage($data, array $attribs = array(), array $params = array(), $content = null) - * @method string htmlQuicktime($data, array $attribs = array(), array $params = array(), $content = null) * @method mixed|null identity() * @method \Laminas\View\Helper\InlineScript inlineScript($mode = \Laminas\View\Helper\HeadScript::FILE, $spec = null, $placement = 'APPEND', array $attrs = array(), $type = 'text/javascript') * @method string|void json($data, array $jsonOptions = array()) From 2bff6d68f876686c361022b29fa8acc28951ec9f Mon Sep 17 00:00:00 2001 From: George Steel Date: Tue, 1 Feb 2022 16:05:09 +0000 Subject: [PATCH 15/58] Updates baseline after removal of flash messenger Signed-off-by: George Steel --- psalm-baseline.xml | 152 +-------------------------------------------- 1 file changed, 1 insertion(+), 151 deletions(-) diff --git a/psalm-baseline.xml b/psalm-baseline.xml index 85e925272..54bb804b1 100644 --- a/psalm-baseline.xml +++ b/psalm-baseline.xml @@ -149,47 +149,6 @@ $value[$k] - - - null === $this->pluginFlashMessenger - - - $item - - - $escapeHtmlHelper - $pluginFlashMessenger - - - $item - $messagesToPrint - - - $classes - $classes - - - $messagesToPrint[] - $messagesToPrint[] - - - $classes - $classes - $messagesToPrint[] - $messagesToPrint[] - $this->escapeHtmlHelper - - - (bool) $autoEscape - (string) $messageCloseString - (string) $messageOpenFormat - (string) $messageSeparatorString - - - $this->escapeHtmlHelper - $this->escapeHtmlHelper - - $flag === null @@ -1528,51 +1487,7 @@ $config - - - FlashMessenger - FlashMessenger - new FlashMessenger() - - - FlashMessengerFactory - - - $configHelper['message_close_string'] - $configHelper['message_open_format'] - $configHelper['message_separator_string'] - $flashMessenger - - - $configHelper['message_close_string'] - $configHelper['message_open_format'] - $configHelper['message_separator_string'] - $config['view_helper_config'] - - - $config - $configHelper - $controllerPluginManager - $flashMessenger - - - get - get - get - - - $container - - - $requestedName - - - - $this - $this - $this - (bool) $enabled @@ -2220,71 +2135,6 @@ $test - - - $plugin->reveal() - $plugin->reveal() - $this->mvcPluginClass - - - FlashMessenger - new FlashMessenger() - new FlashMessenger() - new FlashMessenger() - new FlashMessenger() - new FlashMessenger() - new FlashMessenger() - - - $args - - - $args[0] - - - $displayInfo - $displayInfo - $displayInfo - $displayInfo - $helper - $helper - $helper - $helper - $helperPluginManager - $helperPluginManager - $helperPluginManager - $helperPluginManager - - - get - get - get - get - render - render - renderCurrent - renderCurrent - willReturn - - - hasCurrentErrorMessages - hasCurrentInfoMessages - hasCurrentMessages - hasCurrentSuccessMessages - hasErrorMessages - hasInfoMessages - hasMessages - hasSuccessMessages - hasWarningMessages - render - render - renderCurrent - renderCurrent - - - getMessagesFromNamespace - - $value @@ -3292,7 +3142,7 @@ $this->getServiceNotFoundException() $this->getServiceNotFoundException() - + $target $target From db23fc8980bb30e6e0afdbd1fcf260303b94f271 Mon Sep 17 00:00:00 2001 From: George Steel Date: Wed, 23 Mar 2022 14:57:09 +0000 Subject: [PATCH 16/58] Lock update post rebase. Remove escaper from dev deps - it crept back in during a merge and is already present in deps Remove flash messenger from dev deps. It is no longer referenced anywhere. Signed-off-by: George Steel --- composer.json | 2 - composer.lock | 153 +-------------------------------------------- psalm-baseline.xml | 40 ++---------- 3 files changed, 5 insertions(+), 190 deletions(-) diff --git a/composer.json b/composer.json index 3473d3847..9809f2179 100644 --- a/composer.json +++ b/composer.json @@ -41,7 +41,6 @@ "require-dev": { "laminas/laminas-authentication": "^2.5", "laminas/laminas-coding-standard": "~2.3.0", - "laminas/laminas-escaper": "^2.5", "laminas/laminas-feed": "^2.15", "laminas/laminas-filter": "^2.13.0", "laminas/laminas-http": "^2.15", @@ -49,7 +48,6 @@ "laminas/laminas-modulemanager": "^2.7.1", "laminas/laminas-mvc": "^3.0", "laminas/laminas-mvc-i18n": "^1.1", - "laminas/laminas-mvc-plugin-flashmessenger": "^1.5.0", "laminas/laminas-navigation": "^2.13.1", "laminas/laminas-paginator": "^2.11.0", "laminas/laminas-permissions-acl": "^2.6", diff --git a/composer.lock b/composer.lock index 082c1ac39..768f9970c 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "0f00486d475406252bb25572f2c9a2d3", + "content-hash": "1fe2f14dfb52ae8faa3d57912fd23764", "packages": [ { "name": "container-interop/container-interop", @@ -1999,75 +1999,6 @@ ], "time": "2022-02-25T14:13:55+00:00" }, - { - "name": "laminas/laminas-mvc-plugin-flashmessenger", - "version": "1.7.0", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-mvc-plugin-flashmessenger.git", - "reference": "420a99df81432140d78799a2e7cb34931fcdd619" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-mvc-plugin-flashmessenger/zipball/420a99df81432140d78799a2e7cb34931fcdd619", - "reference": "420a99df81432140d78799a2e7cb34931fcdd619", - "shasum": "" - }, - "require": { - "laminas/laminas-mvc": "^3.3", - "laminas/laminas-session": "^2.12.0", - "laminas/laminas-stdlib": "^3.6.4", - "laminas/laminas-view": "^2.13.1", - "php": "^7.4 || ~8.0.0 || ~8.1.0" - }, - "conflict": { - "laminas/laminas-mvc": "<3.0.0", - "zendframework/zend-mvc-plugin-flashmessenger": "*" - }, - "require-dev": { - "laminas/laminas-coding-standard": "~2.3.0", - "laminas/laminas-i18n": "^2.13.0", - "phpunit/phpunit": "^9.5.4", - "psalm/plugin-phpunit": "^0.16.1", - "vimeo/psalm": "^4.18" - }, - "type": "library", - "extra": { - "laminas": { - "component": "Laminas\\Mvc\\Plugin\\FlashMessenger" - } - }, - "autoload": { - "psr-4": { - "Laminas\\Mvc\\Plugin\\FlashMessenger\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Plugin for creating and exposing flash messages via laminas-mvc controllers", - "homepage": "https://laminas.dev", - "keywords": [ - "laminas", - "mvc" - ], - "support": { - "chat": "https://laminas.dev/chat", - "docs": "https://docs.laminas.dev/laminas-mvc-plugin-flashmessenger/", - "forum": "https://discourse.laminas.dev", - "issues": "https://github.com/laminas/laminas-mvc-plugin-flashmessenger/issues", - "rss": "https://github.com/laminas/laminas-mvc-plugin-flashmessenger/releases.atom", - "source": "https://github.com/laminas/laminas-mvc-plugin-flashmessenger" - }, - "funding": [ - { - "url": "https://funding.communitybridge.org/projects/laminas-project", - "type": "community_bridge" - } - ], - "time": "2022-01-10T11:32:19+00:00" - }, { "name": "laminas/laminas-navigation", "version": "2.13.2", @@ -2362,88 +2293,6 @@ ], "time": "2021-10-13T16:02:43+00:00" }, - { - "name": "laminas/laminas-session", - "version": "2.12.1", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-session.git", - "reference": "888c6a344e9a4c9f34ab6e09346640eac9be3fcf" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-session/zipball/888c6a344e9a4c9f34ab6e09346640eac9be3fcf", - "reference": "888c6a344e9a4c9f34ab6e09346640eac9be3fcf", - "shasum": "" - }, - "require": { - "laminas/laminas-eventmanager": "^3.4", - "laminas/laminas-stdlib": "^3.6", - "php": "^7.3 || ~8.0.0 || ~8.1.0" - }, - "conflict": { - "zendframework/zend-session": "*" - }, - "require-dev": { - "container-interop/container-interop": "^1.1", - "laminas/laminas-cache": "3.0.x-dev", - "laminas/laminas-cache-storage-adapter-memory": "2.0.x-dev", - "laminas/laminas-coding-standard": "~2.2.1", - "laminas/laminas-db": "^2.13.4", - "laminas/laminas-http": "^2.15", - "laminas/laminas-servicemanager": "^3.7", - "laminas/laminas-validator": "^2.15", - "mongodb/mongodb": "v1.9.x-dev", - "php-mock/php-mock-phpunit": "^1.1.2 || ^2.0", - "phpspec/prophecy-phpunit": "^2.0", - "phpunit/phpunit": "^9.5.9" - }, - "suggest": { - "laminas/laminas-cache": "Laminas\\Cache component", - "laminas/laminas-db": "Laminas\\Db component", - "laminas/laminas-http": "Laminas\\Http component", - "laminas/laminas-servicemanager": "Laminas\\ServiceManager component", - "laminas/laminas-validator": "Laminas\\Validator component", - "mongodb/mongodb": "If you want to use the MongoDB session save handler" - }, - "type": "library", - "extra": { - "laminas": { - "component": "Laminas\\Session", - "config-provider": "Laminas\\Session\\ConfigProvider" - } - }, - "autoload": { - "psr-4": { - "Laminas\\Session\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Object-oriented interface to PHP sessions and storage", - "homepage": "https://laminas.dev", - "keywords": [ - "laminas", - "session" - ], - "support": { - "chat": "https://laminas.dev/chat", - "docs": "https://docs.laminas.dev/laminas-session/", - "forum": "https://discourse.laminas.dev", - "issues": "https://github.com/laminas/laminas-session/issues", - "rss": "https://github.com/laminas/laminas-session/releases.atom", - "source": "https://github.com/laminas/laminas-session" - }, - "funding": [ - { - "url": "https://funding.communitybridge.org/projects/laminas-project", - "type": "community_bridge" - } - ], - "time": "2022-02-15T16:38:29+00:00" - }, { "name": "laminas/laminas-uri", "version": "2.9.1", diff --git a/psalm-baseline.xml b/psalm-baseline.xml index 54bb804b1..172d11226 100644 --- a/psalm-baseline.xml +++ b/psalm-baseline.xml @@ -1,5 +1,5 @@ - + $templatePath @@ -1567,17 +1567,6 @@ clearVariables - - - int - - - $this->options['errorLevel'] - - - $captureTo - - $this->type @@ -1661,27 +1650,6 @@ is_object($variables) - - - $values - - - $child - - - $child - $value - - - $this->getFilterChain()->filter($values['result']) - - - $model - - - $values - - $resolver @@ -3098,7 +3066,7 @@ (new RouterConfigProvider())->getDependencyConfig() - + $router $serviceConfig $test @@ -3111,12 +3079,12 @@ $viewHelpers $viewHelpers - + $urlHelper('test') $urlHelper('test') $urlHelper('test', [], ['force_canonical' => true]) - + bootstrap bootstrap bootstrap From 06ad4e9c380b404886ab60bff85c461354a57c11 Mon Sep 17 00:00:00 2001 From: George Steel Date: Wed, 23 Mar 2022 15:17:09 +0000 Subject: [PATCH 17/58] Remove phpspec/prophecy from dev dependencies Closes #133 Tests removed in this branch contain the last remaining usage of Prophecy Signed-off-by: George Steel --- composer.json | 2 -- composer.lock | 54 +-------------------------------------------------- 2 files changed, 1 insertion(+), 55 deletions(-) diff --git a/composer.json b/composer.json index 9809f2179..e35a3bb6c 100644 --- a/composer.json +++ b/composer.json @@ -53,8 +53,6 @@ "laminas/laminas-permissions-acl": "^2.6", "laminas/laminas-router": "^3.0.1", "laminas/laminas-uri": "^2.5", - "phpspec/prophecy": "^1.12", - "phpspec/prophecy-phpunit": "^2.0", "phpunit/phpunit": "^9.5.5", "psalm/plugin-phpunit": "^0.16.1", "vimeo/psalm": "^4.10" diff --git a/composer.lock b/composer.lock index 768f9970c..72ca879f0 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "1fe2f14dfb52ae8faa3d57912fd23764", + "content-hash": "0f6c6231a3825caaaef211c874c683a6", "packages": [ { "name": "container-interop/container-interop", @@ -2998,58 +2998,6 @@ }, "time": "2021-12-08T12:19:24+00:00" }, - { - "name": "phpspec/prophecy-phpunit", - "version": "v2.0.1", - "source": { - "type": "git", - "url": "https://github.com/phpspec/prophecy-phpunit.git", - "reference": "2d7a9df55f257d2cba9b1d0c0963a54960657177" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/phpspec/prophecy-phpunit/zipball/2d7a9df55f257d2cba9b1d0c0963a54960657177", - "reference": "2d7a9df55f257d2cba9b1d0c0963a54960657177", - "shasum": "" - }, - "require": { - "php": "^7.3 || ^8", - "phpspec/prophecy": "^1.3", - "phpunit/phpunit": "^9.1" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.0-dev" - } - }, - "autoload": { - "psr-4": { - "Prophecy\\PhpUnit\\": "src" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Christophe Coevoet", - "email": "stof@notk.org" - } - ], - "description": "Integrating the Prophecy mocking library in PHPUnit test cases", - "homepage": "http://phpspec.net", - "keywords": [ - "phpunit", - "prophecy" - ], - "support": { - "issues": "https://github.com/phpspec/prophecy-phpunit/issues", - "source": "https://github.com/phpspec/prophecy-phpunit/tree/v2.0.1" - }, - "time": "2020-07-09T08:33:42+00:00" - }, { "name": "phpstan/phpdoc-parser", "version": "1.2.0", From ad1a3901dd7aa49fc8518f76fc3785a3bb629951 Mon Sep 17 00:00:00 2001 From: Abdul Malik Ikhsan Date: Tue, 2 Jun 2020 22:12:38 +0700 Subject: [PATCH 18/58] remove deprecated const EOL in AbstractHtmlElement Signed-off-by: Abdul Malik Ikhsan --- src/Helper/AbstractHtmlElement.php | 9 --------- 1 file changed, 9 deletions(-) diff --git a/src/Helper/AbstractHtmlElement.php b/src/Helper/AbstractHtmlElement.php index e14a39ef0..cfa18d2bc 100644 --- a/src/Helper/AbstractHtmlElement.php +++ b/src/Helper/AbstractHtmlElement.php @@ -11,17 +11,8 @@ use function substr; use function trim; -use const PHP_EOL; - abstract class AbstractHtmlElement extends AbstractHelper { - /** - * EOL character - * - * @deprecated just use PHP_EOL - */ - public const EOL = PHP_EOL; - /** * The tag closing bracket * From 4ad9ca5fca12c28bd1ebbb7b7d280c60af53ace6 Mon Sep 17 00:00:00 2001 From: Abdul Malik Ikhsan Date: Fri, 17 Jul 2020 10:46:52 +0700 Subject: [PATCH 19/58] Fixes #7 Fix Placeholder view helper return value Signed-off-by: Abdul Malik Ikhsan --- src/Helper/Placeholder.php | 4 +--- test/Helper/PlaceholderTest.php | 22 ++++++++++++++++++++++ 2 files changed, 23 insertions(+), 3 deletions(-) diff --git a/src/Helper/Placeholder.php b/src/Helper/Placeholder.php index d6713cca6..b1c9acd99 100644 --- a/src/Helper/Placeholder.php +++ b/src/Helper/Placeholder.php @@ -42,9 +42,7 @@ class Placeholder extends AbstractHelper public function __invoke($name = null) { if ($name === null) { - throw new InvalidArgumentException( - 'Placeholder: missing argument. $name is required by placeholder($name)' - ); + return $this; } $name = (string) $name; diff --git a/test/Helper/PlaceholderTest.php b/test/Helper/PlaceholderTest.php index 8295b5533..786f1074e 100644 --- a/test/Helper/PlaceholderTest.php +++ b/test/Helper/PlaceholderTest.php @@ -30,12 +30,26 @@ public function testSetView(): void $this->assertSame($view, $this->placeholder->getView()); } + public function testContainerExists(): void + { + $this->placeholder->__invoke('foo'); + $containerExists = $this->placeholder->__invoke()->containerExists('foo'); + + $this->assertTrue($containerExists); + } + public function testPlaceholderRetrievesContainer(): void { $container = $this->placeholder->__invoke('foo'); $this->assertInstanceOf(AbstractContainer::class, $container); } + public function testPlaceholderRetrievesItself(): void + { + $container = $this->placeholder->__invoke(); + $this->assertSame($container, $this->placeholder); + } + public function testPlaceholderRetrievesSameContainerOnSubsequentCalls(): void { $container1 = $this->placeholder->__invoke('foo'); @@ -67,4 +81,12 @@ public function testClearContainersRemovesAllContainers(): void $this->assertFalse($this->placeholder->containerExists('foo')); $this->assertFalse($this->placeholder->containerExists('bar')); } + + public function testGetContainerRetrievesTheCorrectContainer(): void + { + $container1 = $this->placeholder->__invoke('foo'); + $container2 = $this->placeholder->__invoke()->getContainer('foo'); + + $this->assertSame($container1, $container2); + } } From 3439bb62a61b281a0ffa062def434828bb846101 Mon Sep 17 00:00:00 2001 From: George Steel Date: Wed, 23 Mar 2022 20:34:13 +0000 Subject: [PATCH 20/58] Fixes psalm errors for argument dependent return type Signed-off-by: George Steel --- src/Helper/Placeholder.php | 5 ++++- test/Helper/PlaceholderTest.php | 7 +++---- 2 files changed, 7 insertions(+), 5 deletions(-) diff --git a/src/Helper/Placeholder.php b/src/Helper/Placeholder.php index b1c9acd99..6566c4807 100644 --- a/src/Helper/Placeholder.php +++ b/src/Helper/Placeholder.php @@ -37,7 +37,10 @@ class Placeholder extends AbstractHelper * * @param string $name * @throws InvalidArgumentException - * @return AbstractContainer + * @return AbstractContainer|self + * @psalm-template T of string|null + * @psalm-param T $name + * @psalm-return (T is null ? self : AbstractContainer) */ public function __invoke($name = null) { diff --git a/test/Helper/PlaceholderTest.php b/test/Helper/PlaceholderTest.php index 786f1074e..ff5b98ffd 100644 --- a/test/Helper/PlaceholderTest.php +++ b/test/Helper/PlaceholderTest.php @@ -4,15 +4,14 @@ namespace LaminasTest\View\Helper; -use Laminas\View\Helper; +use Laminas\View\Helper\Placeholder; use Laminas\View\Helper\Placeholder\Container\AbstractContainer; use Laminas\View\Renderer\PhpRenderer as View; use PHPUnit\Framework\TestCase; class PlaceholderTest extends TestCase { - /** @var Helper\Placeholder */ - public $placeholder; + public Placeholder $placeholder; /** * Sets up the fixture, for example, open a network connection. @@ -20,7 +19,7 @@ class PlaceholderTest extends TestCase */ protected function setUp(): void { - $this->placeholder = new Helper\Placeholder(); + $this->placeholder = new Placeholder(); } public function testSetView(): void From d9232e6f4a0c784ee832f1608dbca0cf3a32249d Mon Sep 17 00:00:00 2001 From: George Steel Date: Wed, 23 Mar 2022 22:39:22 +0000 Subject: [PATCH 21/58] Resolve deprecations in Asset view helper Removes deprecated methods and inheritance in the Asset helper, marking it final. Removes factory interface inheritance and swaps service manager for container interface Removes deprecated/obsolete tests Signed-off-by: George Steel --- src/Helper/Asset.php | 35 ++-------------- src/Helper/Service/AssetFactory.php | 36 +++------------- test/Helper/Service/AssetFactoryTest.php | 53 ++++-------------------- 3 files changed, 17 insertions(+), 107 deletions(-) diff --git a/src/Helper/Asset.php b/src/Helper/Asset.php index 34deac7a0..86471f7fc 100644 --- a/src/Helper/Asset.php +++ b/src/Helper/Asset.php @@ -11,15 +11,11 @@ /** * View helper plugin to fetch asset from resource map. - * - * @final */ -class Asset extends AbstractHelper +final class Asset { - use DeprecatedAbstractHelperHierarchyTrait; - /** @var array */ - protected $resourceMap = []; + private array $resourceMap; /** * @param array $resourceMap @@ -34,7 +30,7 @@ public function __construct(array $resourceMap = []) * @return non-empty-string * @throws Exception\InvalidArgumentException */ - public function __invoke($asset) + public function __invoke(string $asset): string { if (! array_key_exists($asset, $this->resourceMap)) { throw new Exception\InvalidArgumentException(sprintf( @@ -45,29 +41,4 @@ public function __invoke($asset) return $this->resourceMap[$asset]; } - - /** - * @deprecated since 2.20.0, this method will be removed in version 3.0.0 of this component. - * The Resource map should be provided to the constructor from version 3.0 - * - * @param array $resourceMap - * @return $this - */ - public function setResourceMap(array $resourceMap) - { - $this->resourceMap = $resourceMap; - - return $this; - } - - /** - * @deprecated since 2.20.0, this method will be removed in version 3.0.0 of this component. - * Runtime retrieval of the resource map from the view will be removed without replacement. - * - * @return array - */ - public function getResourceMap() - { - return $this->resourceMap; - } } diff --git a/src/Helper/Service/AssetFactory.php b/src/Helper/Service/AssetFactory.php index 6de9dea4e..99658c8a1 100644 --- a/src/Helper/Service/AssetFactory.php +++ b/src/Helper/Service/AssetFactory.php @@ -4,11 +4,9 @@ namespace Laminas\View\Helper\Service; -use Interop\Container\ContainerInterface; -use Laminas\ServiceManager\FactoryInterface; -use Laminas\ServiceManager\ServiceLocatorInterface; -use Laminas\View\Exception; +use Laminas\View\Exception\RuntimeException; use Laminas\View\Helper\Asset; +use Psr\Container\ContainerInterface; use Traversable; use function gettype; @@ -16,19 +14,12 @@ use function iterator_to_array; use function sprintf; -/** - * @final - * @psalm-suppress DeprecatedInterface Compatibility with Service Manager 2 should be removed in version 3.0. - */ -class AssetFactory implements FactoryInterface +final class AssetFactory { /** - * @param string $name - * @param null|array $options - * @return Asset - * @throws Exception\RuntimeException + * @throws RuntimeException */ - public function __invoke(ContainerInterface $container, $name, ?array $options = null) + public function __invoke(ContainerInterface $container): Asset { /** @psalm-var mixed $config */ $config = $container->get('config'); @@ -44,21 +35,6 @@ public function __invoke(ContainerInterface $container, $name, ?array $options = return new Asset($resourceMap); } - /** - * Create service - * - * @deprecated since 2.20.0, this method will be removed in version 3.0.0 of this component. - * Compatibility with the 2.x series of Laminas\ServiceManager is no longer supported. - * - * @param string|null $rName - * @param string|null $cName - * @return Asset - */ - public function createService(ServiceLocatorInterface $serviceLocator, $rName = null, $cName = null) - { - return $this($serviceLocator, $cName); - } - /** * @param array $array * @return array @@ -67,7 +43,7 @@ private function assertArray(string $key, array $array): array { $value = $array[$key] ?? []; if (! is_array($value)) { - throw new Exception\RuntimeException(sprintf( + throw new RuntimeException(sprintf( 'Invalid resource map configuration. ' . 'Expected the key "%s" to contain an array value but received "%s"', $key, diff --git a/test/Helper/Service/AssetFactoryTest.php b/test/Helper/Service/AssetFactoryTest.php index ddbcd3df1..1f07ee356 100644 --- a/test/Helper/Service/AssetFactoryTest.php +++ b/test/Helper/Service/AssetFactoryTest.php @@ -4,61 +4,24 @@ namespace LaminasTest\View\Helper\Service; -use Laminas\ServiceManager\ServiceManager; -use Laminas\View\Exception; +use Laminas\View\Exception\RuntimeException; use Laminas\View\Helper\Asset; use Laminas\View\Helper\Service\AssetFactory; use PHPUnit\Framework\TestCase; +use Psr\Container\ContainerInterface; class AssetFactoryTest extends TestCase { - /** - * @deprecated for removal in 3.0 - */ - public function testAssetFactoryCreateServiceCreatesAssetInstance(): void - { - $services = $this->getServices(); - - $assetFactory = new AssetFactory(); - $asset = $assetFactory->createService($services); - - $this->assertInstanceOf(Asset::class, $asset); - } - public function testAssetFactoryInvokableCreatesAssetInstance(): void { $services = $this->getServices(); $assetFactory = new AssetFactory(); - $asset = $assetFactory($services, ''); + $asset = $assetFactory($services); $this->assertInstanceOf(Asset::class, $asset); } - /** - * @deprecated for removal in 3.0 - */ - public function testValidConfiguration(): void - { - $config = [ - 'view_helper_config' => [ - 'asset' => [ - 'resource_map' => [ - 'css/style.css' => 'css/style-3a97ff4ee3.css', - 'js/vendor.js' => 'js/vendor-a507086eba.js', - ], - ], - ], - ]; - - $services = $this->getServices($config); - $assetFactory = new AssetFactory(); - - $asset = $assetFactory($services, ''); - - $this->assertEquals($config['view_helper_config']['asset']['resource_map'], $asset->getResourceMap()); - } - public function testThatAnExceptionWillBeThrownWhenTheResourceMapIsSetToANonArray(): void { $container = $this->getServices([ @@ -69,12 +32,12 @@ public function testThatAnExceptionWillBeThrownWhenTheResourceMapIsSetToANonArra ], ]); - $this->expectException(Exception\RuntimeException::class); + $this->expectException(RuntimeException::class); $this->expectExceptionMessage( 'Invalid resource map configuration. Expected the key ' . '"resource_map" to contain an array value but received "string"' ); - (new AssetFactory())($container, ''); + (new AssetFactory())($container); } /** @@ -129,14 +92,14 @@ public function validConfigProvider(): array public function testThatAnExceptionWillNotBeThrownWhenGivenUnsetOrEmptyArrayConfiguration(array $config): void { $container = $this->getServices($config); - (new AssetFactory())($container, 'foo'); + (new AssetFactory())($container); self::assertTrue(true); } /** @param array $config */ - private function getServices(array $config = []): ServiceManager + private function getServices(array $config = []): ContainerInterface { - $services = $this->createMock(ServiceManager::class); + $services = $this->createMock(ContainerInterface::class); $services->expects(self::once()) ->method('get') ->with('config') From 7686f1c182523f81ebf0ba72549f46f746da6b9c Mon Sep 17 00:00:00 2001 From: George Steel Date: Wed, 23 Mar 2022 22:54:12 +0000 Subject: [PATCH 22/58] Resolve deprecations in Identity view helper Removes deprecated methods and inheritance in the Identity helper, marking it final. Removes factory interface inheritance and swaps service manager for container interface Fixes factory tests to test helper behaviour instead of calling removed service getter. Signed-off-by: George Steel --- src/Helper/Identity.php | 36 ++------------------- src/Helper/Service/IdentityFactory.php | 28 ++-------------- test/Helper/Service/IdentityFactoryTest.php | 15 +++++++-- 3 files changed, 18 insertions(+), 61 deletions(-) diff --git a/src/Helper/Identity.php b/src/Helper/Identity.php index fde997743..6a5ed5150 100644 --- a/src/Helper/Identity.php +++ b/src/Helper/Identity.php @@ -10,12 +10,9 @@ /** * View helper plugin to fetch the authenticated identity. */ -class Identity extends AbstractHelper +final class Identity { - use DeprecatedAbstractHelperHierarchyTrait; - - /** @var AuthenticationServiceInterface|null */ - protected $authenticationService; + private ?AuthenticationServiceInterface $authenticationService; public function __construct(?AuthenticationServiceInterface $authenticationService = null) { @@ -28,6 +25,7 @@ public function __construct(?AuthenticationServiceInterface $authenticationServi * If none available, returns null. * * @return mixed|null + * @throws RuntimeException If the helper was not configured with an Authentication Service. */ public function __invoke() { @@ -40,32 +38,4 @@ public function __invoke() ? $service->getIdentity() : null; } - - /** - * Set AuthenticationService instance - * - * @deprecated since >= 2.20.0. The authentication service should be provided to the constructor. This method will - * be removed in version 3.0 of this component - * - * @return $this - */ - public function setAuthenticationService(AuthenticationServiceInterface $authenticationService) - { - $this->authenticationService = $authenticationService; - - return $this; - } - - /** - * Get AuthenticationService instance - * - * @deprecated since >= 2.20.0. The authentication service should be provided to the constructor. This method will - * be removed in version 3.0 of this component - * - * @return null|object - */ - public function getAuthenticationService() - { - return $this->authenticationService; - } } diff --git a/src/Helper/Service/IdentityFactory.php b/src/Helper/Service/IdentityFactory.php index 220eba77b..6962fbae4 100644 --- a/src/Helper/Service/IdentityFactory.php +++ b/src/Helper/Service/IdentityFactory.php @@ -4,42 +4,20 @@ namespace Laminas\View\Helper\Service; -use Interop\Container\ContainerInterface; use Laminas\Authentication\AuthenticationService; use Laminas\Authentication\AuthenticationServiceInterface; -use Laminas\ServiceManager\FactoryInterface; -use Laminas\ServiceManager\ServiceLocatorInterface; use Laminas\View\Helper\Identity; +use Psr\Container\ContainerInterface; use function assert; -/** - * @psalm-suppress DeprecatedInterface - */ -class IdentityFactory implements FactoryInterface +final class IdentityFactory { - /** - * @param string|null $name - * @param array|null $options - * @return Identity - */ - public function __invoke(ContainerInterface $container, $name = null, ?array $options = null) + public function __invoke(ContainerInterface $container): Identity { return new Identity($this->discoverAuthenticationService($container)); } - /** - * Create service - * - * @param string|null $rName - * @param string|null $cName - * @return Identity - */ - public function createService(ServiceLocatorInterface $serviceLocator, $rName = null, $cName = null) - { - return $this($serviceLocator, $cName); - } - private function discoverAuthenticationService(ContainerInterface $container): ?AuthenticationServiceInterface { if ($container->has(AuthenticationService::class)) { diff --git a/test/Helper/Service/IdentityFactoryTest.php b/test/Helper/Service/IdentityFactoryTest.php index ba3544dd0..581a3c3e6 100644 --- a/test/Helper/Service/IdentityFactoryTest.php +++ b/test/Helper/Service/IdentityFactoryTest.php @@ -7,6 +7,7 @@ use Interop\Container\ContainerInterface; use Laminas\Authentication\AuthenticationService; use Laminas\Authentication\AuthenticationServiceInterface; +use Laminas\View\Exception\RuntimeException; use Laminas\View\Helper\Identity; use Laminas\View\Helper\Service\IdentityFactory; use PHPUnit\Framework\MockObject\MockObject; @@ -36,12 +37,17 @@ public function testFactoryReturnsEmptyIdentityIfNoAuthenticationServicePresent( $plugin = $factory($this->services); $this->assertInstanceOf(Identity::class, $plugin); - $this->assertNull($plugin->getAuthenticationService()); + $this->expectException(RuntimeException::class); + $plugin(); } public function testFactoryReturnsIdentityWithConfiguredAuthenticationServiceWhenPresent(): void { $authService = $this->createMock(AuthenticationServiceInterface::class); + $authService->expects(self::once()) + ->method('hasIdentity') + ->willReturn(false); + $this->services->expects(self::once()) ->method('has') ->with(AuthenticationService::class) @@ -57,12 +63,15 @@ public function testFactoryReturnsIdentityWithConfiguredAuthenticationServiceWhe $plugin = $factory($this->services); $this->assertInstanceOf(Identity::class, $plugin); - $this->assertSame($authService, $plugin->getAuthenticationService()); + $this->assertNull($plugin()); } public function testFactoryReturnsIdentityWithConfiguredAuthenticationServiceInterfaceWhenPresent(): void { $authService = $this->createMock(AuthenticationServiceInterface::class); + $authService->expects(self::once()) + ->method('hasIdentity') + ->willReturn(false); $this->services->expects(self::exactly(2)) ->method('has') @@ -78,6 +87,6 @@ public function testFactoryReturnsIdentityWithConfiguredAuthenticationServiceInt $plugin = $factory($this->services); $this->assertInstanceOf(Identity::class, $plugin); - $this->assertSame($authService, $plugin->getAuthenticationService()); + $this->assertNull($plugin()); } } From 70c450bcd990e59fb60e4dbde6e5fc5856e3b46a Mon Sep 17 00:00:00 2001 From: George Steel Date: Sun, 10 Jul 2022 22:56:01 +0100 Subject: [PATCH 23/58] Resolves merge conflicts from 2.21.x, updating locked dependencies Signed-off-by: George Steel --- composer.lock | 474 +++++++++----------- psalm-baseline.xml | 231 +--------- src/Helper/Json.php | 4 +- test/Helper/Service/IdentityFactoryTest.php | 2 +- 4 files changed, 249 insertions(+), 462 deletions(-) diff --git a/composer.lock b/composer.lock index 72ca879f0..1eeb5e6bd 100644 --- a/composer.lock +++ b/composer.lock @@ -4,44 +4,8 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "0f6c6231a3825caaaef211c874c683a6", + "content-hash": "f636204767b9525986897d0dc7ef0038", "packages": [ - { - "name": "container-interop/container-interop", - "version": "1.2.0", - "source": { - "type": "git", - "url": "https://github.com/container-interop/container-interop.git", - "reference": "79cbf1341c22ec75643d841642dd5d6acd83bdb8" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/container-interop/container-interop/zipball/79cbf1341c22ec75643d841642dd5d6acd83bdb8", - "reference": "79cbf1341c22ec75643d841642dd5d6acd83bdb8", - "shasum": "" - }, - "require": { - "psr/container": "^1.0" - }, - "type": "library", - "autoload": { - "psr-4": { - "Interop\\Container\\": "src/Interop/Container/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "description": "Promoting the interoperability of container objects (DIC, SL, etc.)", - "homepage": "https://github.com/container-interop/container-interop", - "support": { - "issues": "https://github.com/container-interop/container-interop/issues", - "source": "https://github.com/container-interop/container-interop/tree/master" - }, - "abandoned": "psr/container", - "time": "2017-02-14T19:40:03+00:00" - }, { "name": "laminas/laminas-escaper", "version": "2.10.0", @@ -106,35 +70,36 @@ }, { "name": "laminas/laminas-eventmanager", - "version": "3.4.0", + "version": "3.5.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-eventmanager.git", - "reference": "a93fd278c97b2d41ebbce5ba048a24e3e6f580ba" + "reference": "41f7209428f37cab9573365e361f4078209aaafa" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-eventmanager/zipball/a93fd278c97b2d41ebbce5ba048a24e3e6f580ba", - "reference": "a93fd278c97b2d41ebbce5ba048a24e3e6f580ba", + "url": "https://api.github.com/repos/laminas/laminas-eventmanager/zipball/41f7209428f37cab9573365e361f4078209aaafa", + "reference": "41f7209428f37cab9573365e361f4078209aaafa", "shasum": "" }, "require": { - "php": "^7.3 || ~8.0.0 || ~8.1.0" + "php": "^7.4 || ~8.0.0 || ~8.1.0" }, "conflict": { + "container-interop/container-interop": "<1.2", "zendframework/zend-eventmanager": "*" }, "require-dev": { - "container-interop/container-interop": "^1.1", "laminas/laminas-coding-standard": "~2.2.1", "laminas/laminas-stdlib": "^3.6", "phpbench/phpbench": "^1.1", "phpspec/prophecy-phpunit": "^2.0", - "phpunit/phpunit": "^9.5.5" + "phpunit/phpunit": "^9.5.5", + "psr/container": "^1.1.2 || ^2.0.2" }, "suggest": { - "container-interop/container-interop": "^1.1, to use the lazy listeners feature", - "laminas/laminas-stdlib": "^2.7.3 || ^3.0, to use the FilterChain feature" + "laminas/laminas-stdlib": "^2.7.3 || ^3.0, to use the FilterChain feature", + "psr/container": "^1.1.2 || ^2.0.2, to use the lazy listeners feature" }, "type": "library", "autoload": { @@ -168,7 +133,7 @@ "type": "community_bridge" } ], - "time": "2021-09-07T22:35:32+00:00" + "time": "2022-04-06T21:05:17+00:00" }, { "name": "laminas/laminas-json", @@ -233,44 +198,46 @@ }, { "name": "laminas/laminas-servicemanager", - "version": "3.10.0", + "version": "3.14.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-servicemanager.git", - "reference": "e52b985909e0940bf22d34f322eb3f48bbef6bd1" + "reference": "918de970b2c3d42acebff3d431d76db52b6a32a2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-servicemanager/zipball/e52b985909e0940bf22d34f322eb3f48bbef6bd1", - "reference": "e52b985909e0940bf22d34f322eb3f48bbef6bd1", + "url": "https://api.github.com/repos/laminas/laminas-servicemanager/zipball/918de970b2c3d42acebff3d431d76db52b6a32a2", + "reference": "918de970b2c3d42acebff3d431d76db52b6a32a2", "shasum": "" }, "require": { - "container-interop/container-interop": "^1.2", "laminas/laminas-stdlib": "^3.2.1", "php": "~7.4.0 || ~8.0.0 || ~8.1.0", "psr/container": "^1.0" }, "conflict": { + "ext-psr": "*", "laminas/laminas-code": "<3.3.1", "zendframework/zend-code": "<3.3.1", "zendframework/zend-servicemanager": "*" }, "provide": { - "container-interop/container-interop-implementation": "^1.2", "psr/container-implementation": "^1.0" }, + "replace": { + "container-interop/container-interop": "^1.2.0" + }, "require-dev": { "composer/package-versions-deprecated": "^1.0", - "laminas/laminas-coding-standard": "~2.2.1", - "laminas/laminas-container-config-test": "^0.3", + "laminas/laminas-coding-standard": "~2.3.0", + "laminas/laminas-container-config-test": "^0.6", "laminas/laminas-dependency-plugin": "^2.1.2", "mikey179/vfsstream": "^1.6.10@alpha", "ocramius/proxy-manager": "^2.11", "phpbench/phpbench": "^1.1", "phpspec/prophecy-phpunit": "^2.0", "phpunit/phpunit": "^9.5.5", - "psalm/plugin-phpunit": "^0.16.1", + "psalm/plugin-phpunit": "^0.17.0", "vimeo/psalm": "^4.8" }, "suggest": { @@ -282,6 +249,9 @@ ], "type": "library", "autoload": { + "files": [ + "src/autoload.php" + ], "psr-4": { "Laminas\\ServiceManager\\": "src/" } @@ -315,20 +285,20 @@ "type": "community_bridge" } ], - "time": "2021-09-18T20:19:36+00:00" + "time": "2022-07-07T16:13:26+00:00" }, { "name": "laminas/laminas-stdlib", - "version": "3.7.1", + "version": "3.10.1", "source": { "type": "git", "url": "https://github.com/laminas/laminas-stdlib.git", - "reference": "bcd869e2fe88d567800057c1434f2380354fe325" + "reference": "0d669074845fc80a99add0f64025192f143ef836" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-stdlib/zipball/bcd869e2fe88d567800057c1434f2380354fe325", - "reference": "bcd869e2fe88d567800057c1434f2380354fe325", + "url": "https://api.github.com/repos/laminas/laminas-stdlib/zipball/0d669074845fc80a99add0f64025192f143ef836", + "reference": "0d669074845fc80a99add0f64025192f143ef836", "shasum": "" }, "require": { @@ -374,7 +344,7 @@ "type": "community_bridge" } ], - "time": "2022-01-21T15:50:46+00:00" + "time": "2022-06-10T14:49:09+00:00" }, { "name": "psr/container", @@ -594,16 +564,16 @@ }, { "name": "brick/varexporter", - "version": "0.3.5", + "version": "0.3.7", "source": { "type": "git", "url": "https://github.com/brick/varexporter.git", - "reference": "05241f28dfcba2b51b11e2d750e296316ebbe518" + "reference": "3e263cd718d242594c52963760fee2059fd5833c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/brick/varexporter/zipball/05241f28dfcba2b51b11e2d750e296316ebbe518", - "reference": "05241f28dfcba2b51b11e2d750e296316ebbe518", + "url": "https://api.github.com/repos/brick/varexporter/zipball/3e263cd718d242594c52963760fee2059fd5833c", + "reference": "3e263cd718d242594c52963760fee2059fd5833c", "shasum": "" }, "require": { @@ -613,7 +583,7 @@ "require-dev": { "php-coveralls/php-coveralls": "^2.2", "phpunit/phpunit": "^8.5 || ^9.0", - "vimeo/psalm": "4.4.1" + "vimeo/psalm": "4.23.0" }, "type": "library", "autoload": { @@ -631,9 +601,15 @@ ], "support": { "issues": "https://github.com/brick/varexporter/issues", - "source": "https://github.com/brick/varexporter/tree/0.3.5" + "source": "https://github.com/brick/varexporter/tree/0.3.7" }, - "time": "2021-02-10T13:53:07+00:00" + "funding": [ + { + "url": "https://github.com/BenMorel", + "type": "github" + } + ], + "time": "2022-06-29T23:37:57+00:00" }, { "name": "composer/package-versions-deprecated", @@ -781,16 +757,16 @@ }, { "name": "composer/semver", - "version": "3.3.1", + "version": "3.3.2", "source": { "type": "git", "url": "https://github.com/composer/semver.git", - "reference": "5d8e574bb0e69188786b8ef77d43341222a41a71" + "reference": "3953f23262f2bff1919fc82183ad9acb13ff62c9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/semver/zipball/5d8e574bb0e69188786b8ef77d43341222a41a71", - "reference": "5d8e574bb0e69188786b8ef77d43341222a41a71", + "url": "https://api.github.com/repos/composer/semver/zipball/3953f23262f2bff1919fc82183ad9acb13ff62c9", + "reference": "3953f23262f2bff1919fc82183ad9acb13ff62c9", "shasum": "" }, "require": { @@ -842,7 +818,7 @@ "support": { "irc": "irc://irc.freenode.org/composer", "issues": "https://github.com/composer/semver/issues", - "source": "https://github.com/composer/semver/tree/3.3.1" + "source": "https://github.com/composer/semver/tree/3.3.2" }, "funding": [ { @@ -858,7 +834,7 @@ "type": "tidelift" } ], - "time": "2022-03-16T11:22:07+00:00" + "time": "2022-04-01T19:23:25+00:00" }, { "name": "composer/xdebug-handler", @@ -1155,16 +1131,16 @@ }, { "name": "felixfbecker/language-server-protocol", - "version": "1.5.1", + "version": "v1.5.2", "source": { "type": "git", "url": "https://github.com/felixfbecker/php-language-server-protocol.git", - "reference": "9d846d1f5cf101deee7a61c8ba7caa0a975cd730" + "reference": "6e82196ffd7c62f7794d778ca52b69feec9f2842" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/felixfbecker/php-language-server-protocol/zipball/9d846d1f5cf101deee7a61c8ba7caa0a975cd730", - "reference": "9d846d1f5cf101deee7a61c8ba7caa0a975cd730", + "url": "https://api.github.com/repos/felixfbecker/php-language-server-protocol/zipball/6e82196ffd7c62f7794d778ca52b69feec9f2842", + "reference": "6e82196ffd7c62f7794d778ca52b69feec9f2842", "shasum": "" }, "require": { @@ -1205,22 +1181,22 @@ ], "support": { "issues": "https://github.com/felixfbecker/php-language-server-protocol/issues", - "source": "https://github.com/felixfbecker/php-language-server-protocol/tree/1.5.1" + "source": "https://github.com/felixfbecker/php-language-server-protocol/tree/v1.5.2" }, - "time": "2021-02-22T14:02:09+00:00" + "time": "2022-03-02T22:36:06+00:00" }, { "name": "laminas/laminas-authentication", - "version": "2.10.1", + "version": "2.11.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-authentication.git", - "reference": "7308db03e11147fbf567b5004ac428bdaba267f9" + "reference": "51815691d862b82b749a4aa9c4f6ec078d579f74" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-authentication/zipball/7308db03e11147fbf567b5004ac428bdaba267f9", - "reference": "7308db03e11147fbf567b5004ac428bdaba267f9", + "url": "https://api.github.com/repos/laminas/laminas-authentication/zipball/51815691d862b82b749a4aa9c4f6ec078d579f74", + "reference": "51815691d862b82b749a4aa9c4f6ec078d579f74", "shasum": "" }, "require": { @@ -1231,7 +1207,7 @@ "zendframework/zend-authentication": "*" }, "require-dev": { - "laminas/laminas-coding-standard": "~1.0.0", + "laminas/laminas-coding-standard": "~2.3.0", "laminas/laminas-crypt": "^2.6 || ^3.2.1", "laminas/laminas-db": "^2.13", "laminas/laminas-http": "^2.15.0", @@ -1283,7 +1259,7 @@ "type": "community_bridge" } ], - "time": "2022-03-09T23:07:57+00:00" + "time": "2022-06-23T10:41:36+00:00" }, { "name": "laminas/laminas-coding-standard", @@ -1408,16 +1384,16 @@ }, { "name": "laminas/laminas-feed", - "version": "2.16.0", + "version": "2.17.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-feed.git", - "reference": "cbd0e10c867a1efa6594164d229d8caf4a4ae4c7" + "reference": "1ccb024ea615606ed1d676ba0fa3f22a398f3ac0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-feed/zipball/cbd0e10c867a1efa6594164d229d8caf4a4ae4c7", - "reference": "cbd0e10c867a1efa6594164d229d8caf4a4ae4c7", + "url": "https://api.github.com/repos/laminas/laminas-feed/zipball/1ccb024ea615606ed1d676ba0fa3f22a398f3ac0", + "reference": "1ccb024ea615606ed1d676ba0fa3f22a398f3ac0", "shasum": "" }, "require": { @@ -1481,7 +1457,7 @@ "type": "community_bridge" } ], - "time": "2021-12-17T09:12:35+00:00" + "time": "2022-03-24T10:26:04+00:00" }, { "name": "laminas/laminas-filter", @@ -1629,16 +1605,16 @@ }, { "name": "laminas/laminas-i18n", - "version": "2.14.0", + "version": "2.15.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-i18n.git", - "reference": "1fa15c41b683bedb2a846af54491868ddc73db38" + "reference": "1654fcd6cd27c01a902b47fe71fa583ad227268c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-i18n/zipball/1fa15c41b683bedb2a846af54491868ddc73db38", - "reference": "1fa15c41b683bedb2a846af54491868ddc73db38", + "url": "https://api.github.com/repos/laminas/laminas-i18n/zipball/1654fcd6cd27c01a902b47fe71fa583ad227268c", + "reference": "1654fcd6cd27c01a902b47fe71fa583ad227268c", "shasum": "" }, "require": { @@ -1647,6 +1623,7 @@ "php": "^7.4 || ~8.0.0 || ~8.1.0" }, "conflict": { + "laminas/laminas-view": "<2.20.0", "phpspec/prophecy": "<1.9.0", "zendframework/zend-i18n": "*" }, @@ -1660,7 +1637,7 @@ "laminas/laminas-filter": "^2.10.0", "laminas/laminas-servicemanager": "^3.7.0", "laminas/laminas-validator": "^2.14.0", - "laminas/laminas-view": "^2.12.0", + "laminas/laminas-view": "^2.20.0", "phpspec/prophecy-phpunit": "^2.0", "phpunit/phpunit": "^9.3", "psalm/plugin-phpunit": "^0.16.1", @@ -1712,7 +1689,7 @@ "type": "community_bridge" } ], - "time": "2022-02-21T20:41:26+00:00" + "time": "2022-04-01T10:47:19+00:00" }, { "name": "laminas/laminas-loader", @@ -2353,22 +2330,22 @@ }, { "name": "laminas/laminas-validator", - "version": "2.17.0", + "version": "2.20.1", "source": { "type": "git", "url": "https://github.com/laminas/laminas-validator.git", - "reference": "bdd503adc83d814a5c94e598ea0eb9fc7ca56339" + "reference": "90304417929a51e42999b115907a39f4b658c131" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-validator/zipball/bdd503adc83d814a5c94e598ea0eb9fc7ca56339", - "reference": "bdd503adc83d814a5c94e598ea0eb9fc7ca56339", + "url": "https://api.github.com/repos/laminas/laminas-validator/zipball/90304417929a51e42999b115907a39f4b658c131", + "reference": "90304417929a51e42999b115907a39f4b658c131", "shasum": "" }, "require": { - "container-interop/container-interop": "^1.1", - "laminas/laminas-stdlib": "^3.6", - "php": "^7.3 || ~8.0.0 || ~8.1.0" + "laminas/laminas-servicemanager": "^3.12.0", + "laminas/laminas-stdlib": "^3.10", + "php": "^7.4 || ~8.0.0 || ~8.1.0" }, "conflict": { "zendframework/zend-validator": "*" @@ -2377,27 +2354,24 @@ "laminas/laminas-cache": "^2.6.1", "laminas/laminas-coding-standard": "~2.2.1", "laminas/laminas-db": "^2.7", - "laminas/laminas-filter": "^2.6", + "laminas/laminas-filter": "^2.14.0", "laminas/laminas-http": "^2.14.2", - "laminas/laminas-i18n": "^2.6", - "laminas/laminas-math": "^2.6", - "laminas/laminas-servicemanager": "^2.7.11 || ^3.0.3", - "laminas/laminas-session": "^2.8", - "laminas/laminas-uri": "^2.7", + "laminas/laminas-i18n": "^2.15.0", + "laminas/laminas-session": "^2.12.1", + "laminas/laminas-uri": "^2.9.1", "phpspec/prophecy-phpunit": "^2.0", "phpunit/phpunit": "^9.5.5", "psalm/plugin-phpunit": "^0.15.0", "psr/http-client": "^1.0", "psr/http-factory": "^1.0", "psr/http-message": "^1.0", - "vimeo/psalm": "^4.3" + "vimeo/psalm": "^4.23" }, "suggest": { "laminas/laminas-db": "Laminas\\Db component, required by the (No)RecordExists validator", "laminas/laminas-filter": "Laminas\\Filter component, required by the Digits validator", "laminas/laminas-i18n": "Laminas\\I18n component to allow translation of validation error messages", "laminas/laminas-i18n-resources": "Translations of validator messages", - "laminas/laminas-math": "Laminas\\Math component, required by the Csrf validator", "laminas/laminas-servicemanager": "Laminas\\ServiceManager component to allow using the ValidatorPluginManager and validator chains", "laminas/laminas-session": "Laminas\\Session component, ^2.8; required by the Csrf validator", "laminas/laminas-uri": "Laminas\\Uri component, required by the Uri and Sitemap\\Loc validators", @@ -2439,7 +2413,7 @@ "type": "community_bridge" } ], - "time": "2022-03-08T18:16:51+00:00" + "time": "2022-07-01T07:39:15+00:00" }, { "name": "myclabs/deep-copy", @@ -2553,16 +2527,16 @@ }, { "name": "nikic/php-parser", - "version": "v4.13.2", + "version": "v4.14.0", "source": { "type": "git", "url": "https://github.com/nikic/PHP-Parser.git", - "reference": "210577fe3cf7badcc5814d99455df46564f3c077" + "reference": "34bea19b6e03d8153165d8f30bba4c3be86184c1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/210577fe3cf7badcc5814d99455df46564f3c077", - "reference": "210577fe3cf7badcc5814d99455df46564f3c077", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/34bea19b6e03d8153165d8f30bba4c3be86184c1", + "reference": "34bea19b6e03d8153165d8f30bba4c3be86184c1", "shasum": "" }, "require": { @@ -2603,9 +2577,9 @@ ], "support": { "issues": "https://github.com/nikic/PHP-Parser/issues", - "source": "https://github.com/nikic/PHP-Parser/tree/v4.13.2" + "source": "https://github.com/nikic/PHP-Parser/tree/v4.14.0" }, - "time": "2021-11-30T19:35:32+00:00" + "time": "2022-05-31T20:59:12+00:00" }, { "name": "openlss/lib-array2xml", @@ -2883,16 +2857,16 @@ }, { "name": "phpdocumentor/type-resolver", - "version": "1.6.0", + "version": "1.6.1", "source": { "type": "git", "url": "https://github.com/phpDocumentor/TypeResolver.git", - "reference": "93ebd0014cab80c4ea9f5e297ea48672f1b87706" + "reference": "77a32518733312af16a44300404e945338981de3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/93ebd0014cab80c4ea9f5e297ea48672f1b87706", - "reference": "93ebd0014cab80c4ea9f5e297ea48672f1b87706", + "url": "https://api.github.com/repos/phpDocumentor/TypeResolver/zipball/77a32518733312af16a44300404e945338981de3", + "reference": "77a32518733312af16a44300404e945338981de3", "shasum": "" }, "require": { @@ -2927,9 +2901,9 @@ "description": "A PSR-5 based resolver of Class names, Types and Structural Element Names", "support": { "issues": "https://github.com/phpDocumentor/TypeResolver/issues", - "source": "https://github.com/phpDocumentor/TypeResolver/tree/1.6.0" + "source": "https://github.com/phpDocumentor/TypeResolver/tree/1.6.1" }, - "time": "2022-01-04T19:58:01+00:00" + "time": "2022-03-15T21:29:03+00:00" }, { "name": "phpspec/prophecy", @@ -3000,35 +2974,31 @@ }, { "name": "phpstan/phpdoc-parser", - "version": "1.2.0", + "version": "1.6.4", "source": { "type": "git", "url": "https://github.com/phpstan/phpdoc-parser.git", - "reference": "dbc093d7af60eff5cd575d2ed761b15ed40bd08e" + "reference": "135607f9ccc297d6923d49c2bcf309f509413215" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpstan/phpdoc-parser/zipball/dbc093d7af60eff5cd575d2ed761b15ed40bd08e", - "reference": "dbc093d7af60eff5cd575d2ed761b15ed40bd08e", + "url": "https://api.github.com/repos/phpstan/phpdoc-parser/zipball/135607f9ccc297d6923d49c2bcf309f509413215", + "reference": "135607f9ccc297d6923d49c2bcf309f509413215", "shasum": "" }, "require": { - "php": "^7.1 || ^8.0" + "php": "^7.2 || ^8.0" }, "require-dev": { "php-parallel-lint/php-parallel-lint": "^1.2", "phpstan/extension-installer": "^1.0", - "phpstan/phpstan": "^1.0", + "phpstan/phpstan": "^1.5", + "phpstan/phpstan-phpunit": "^1.1", "phpstan/phpstan-strict-rules": "^1.0", "phpunit/phpunit": "^9.5", "symfony/process": "^5.2" }, "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.0-dev" - } - }, "autoload": { "psr-4": { "PHPStan\\PhpDocParser\\": [ @@ -3043,9 +3013,9 @@ "description": "PHPDoc parser with support for nullable, intersection and generic types", "support": { "issues": "https://github.com/phpstan/phpdoc-parser/issues", - "source": "https://github.com/phpstan/phpdoc-parser/tree/1.2.0" + "source": "https://github.com/phpstan/phpdoc-parser/tree/1.6.4" }, - "time": "2021-09-16T20:46:02+00:00" + "time": "2022-06-26T13:09:08+00:00" }, { "name": "phpunit/php-code-coverage", @@ -3367,16 +3337,16 @@ }, { "name": "phpunit/phpunit", - "version": "9.5.19", + "version": "9.5.21", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "35ea4b7f3acabb26f4bb640f8c30866c401da807" + "reference": "0e32b76be457de00e83213528f6bb37e2a38fcb1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/35ea4b7f3acabb26f4bb640f8c30866c401da807", - "reference": "35ea4b7f3acabb26f4bb640f8c30866c401da807", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/0e32b76be457de00e83213528f6bb37e2a38fcb1", + "reference": "0e32b76be457de00e83213528f6bb37e2a38fcb1", "shasum": "" }, "require": { @@ -3410,7 +3380,6 @@ "sebastian/version": "^3.0.2" }, "require-dev": { - "ext-pdo": "*", "phpspec/prophecy-phpunit": "^2.0.1" }, "suggest": { @@ -3454,7 +3423,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", - "source": "https://github.com/sebastianbergmann/phpunit/tree/9.5.19" + "source": "https://github.com/sebastianbergmann/phpunit/tree/9.5.21" }, "funding": [ { @@ -3466,7 +3435,7 @@ "type": "github" } ], - "time": "2022-03-15T09:57:31+00:00" + "time": "2022-06-19T12:14:25+00:00" }, { "name": "psalm/plugin-phpunit", @@ -3944,16 +3913,16 @@ }, { "name": "sebastian/environment", - "version": "5.1.3", + "version": "5.1.4", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/environment.git", - "reference": "388b6ced16caa751030f6a69e588299fa09200ac" + "reference": "1b5dff7bb151a4db11d49d90e5408e4e938270f7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/388b6ced16caa751030f6a69e588299fa09200ac", - "reference": "388b6ced16caa751030f6a69e588299fa09200ac", + "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/1b5dff7bb151a4db11d49d90e5408e4e938270f7", + "reference": "1b5dff7bb151a4db11d49d90e5408e4e938270f7", "shasum": "" }, "require": { @@ -3995,7 +3964,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/environment/issues", - "source": "https://github.com/sebastianbergmann/environment/tree/5.1.3" + "source": "https://github.com/sebastianbergmann/environment/tree/5.1.4" }, "funding": [ { @@ -4003,7 +3972,7 @@ "type": "github" } ], - "time": "2020-09-28T05:52:38+00:00" + "time": "2022-04-03T09:37:03+00:00" }, { "name": "sebastian/exporter", @@ -4544,32 +4513,32 @@ }, { "name": "slevomat/coding-standard", - "version": "7.0.19", + "version": "7.2.1", "source": { "type": "git", "url": "https://github.com/slevomat/coding-standard.git", - "reference": "bef66a43815bbf9b5f49775e9ded3f7c6ba0cc37" + "reference": "aff06ae7a84e4534bf6f821dc982a93a5d477c90" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/slevomat/coding-standard/zipball/bef66a43815bbf9b5f49775e9ded3f7c6ba0cc37", - "reference": "bef66a43815bbf9b5f49775e9ded3f7c6ba0cc37", + "url": "https://api.github.com/repos/slevomat/coding-standard/zipball/aff06ae7a84e4534bf6f821dc982a93a5d477c90", + "reference": "aff06ae7a84e4534bf6f821dc982a93a5d477c90", "shasum": "" }, "require": { "dealerdirect/phpcodesniffer-composer-installer": "^0.6.2 || ^0.7", - "php": "^7.1 || ^8.0", - "phpstan/phpdoc-parser": "^1.0.0", + "php": "^7.2 || ^8.0", + "phpstan/phpdoc-parser": "^1.5.1", "squizlabs/php_codesniffer": "^3.6.2" }, "require-dev": { - "phing/phing": "2.17.2", + "phing/phing": "2.17.3", "php-parallel-lint/php-parallel-lint": "1.3.2", - "phpstan/phpstan": "1.4.6", + "phpstan/phpstan": "1.4.10|1.7.1", "phpstan/phpstan-deprecation-rules": "1.0.0", - "phpstan/phpstan-phpunit": "1.0.0", - "phpstan/phpstan-strict-rules": "1.1.0", - "phpunit/phpunit": "7.5.20|8.5.21|9.5.16" + "phpstan/phpstan-phpunit": "1.0.0|1.1.1", + "phpstan/phpstan-strict-rules": "1.2.3", + "phpunit/phpunit": "7.5.20|8.5.21|9.5.20" }, "type": "phpcodesniffer-standard", "extra": { @@ -4589,7 +4558,7 @@ "description": "Slevomat Coding Standard for PHP_CodeSniffer complements Consistence Coding Standard by providing sniffs with additional checks.", "support": { "issues": "https://github.com/slevomat/coding-standard/issues", - "source": "https://github.com/slevomat/coding-standard/tree/7.0.19" + "source": "https://github.com/slevomat/coding-standard/tree/7.2.1" }, "funding": [ { @@ -4601,20 +4570,20 @@ "type": "tidelift" } ], - "time": "2022-03-01T18:01:41+00:00" + "time": "2022-05-25T10:58:12+00:00" }, { "name": "squizlabs/php_codesniffer", - "version": "3.6.2", + "version": "3.7.1", "source": { "type": "git", "url": "https://github.com/squizlabs/PHP_CodeSniffer.git", - "reference": "5e4e71592f69da17871dba6e80dd51bce74a351a" + "reference": "1359e176e9307e906dc3d890bcc9603ff6d90619" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/5e4e71592f69da17871dba6e80dd51bce74a351a", - "reference": "5e4e71592f69da17871dba6e80dd51bce74a351a", + "url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/1359e176e9307e906dc3d890bcc9603ff6d90619", + "reference": "1359e176e9307e906dc3d890bcc9603ff6d90619", "shasum": "" }, "require": { @@ -4657,20 +4626,20 @@ "source": "https://github.com/squizlabs/PHP_CodeSniffer", "wiki": "https://github.com/squizlabs/PHP_CodeSniffer/wiki" }, - "time": "2021-12-12T21:44:58+00:00" + "time": "2022-06-18T07:21:10+00:00" }, { "name": "symfony/console", - "version": "v5.4.5", + "version": "v5.4.10", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "d8111acc99876953f52fe16d4c50eb60940d49ad" + "reference": "4d671ab4ddac94ee439ea73649c69d9d200b5000" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/d8111acc99876953f52fe16d4c50eb60940d49ad", - "reference": "d8111acc99876953f52fe16d4c50eb60940d49ad", + "url": "https://api.github.com/repos/symfony/console/zipball/4d671ab4ddac94ee439ea73649c69d9d200b5000", + "reference": "4d671ab4ddac94ee439ea73649c69d9d200b5000", "shasum": "" }, "require": { @@ -4740,7 +4709,7 @@ "terminal" ], "support": { - "source": "https://github.com/symfony/console/tree/v5.4.5" + "source": "https://github.com/symfony/console/tree/v5.4.10" }, "funding": [ { @@ -4756,20 +4725,20 @@ "type": "tidelift" } ], - "time": "2022-02-24T12:45:35+00:00" + "time": "2022-06-26T13:00:04+00:00" }, { "name": "symfony/deprecation-contracts", - "version": "v2.5.0", + "version": "v2.5.2", "source": { "type": "git", "url": "https://github.com/symfony/deprecation-contracts.git", - "reference": "6f981ee24cf69ee7ce9736146d1c57c2780598a8" + "reference": "e8b495ea28c1d97b5e0c121748d6f9b53d075c66" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/6f981ee24cf69ee7ce9736146d1c57c2780598a8", - "reference": "6f981ee24cf69ee7ce9736146d1c57c2780598a8", + "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/e8b495ea28c1d97b5e0c121748d6f9b53d075c66", + "reference": "e8b495ea28c1d97b5e0c121748d6f9b53d075c66", "shasum": "" }, "require": { @@ -4807,7 +4776,7 @@ "description": "A generic function and convention to trigger deprecation notices", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/deprecation-contracts/tree/v2.5.0" + "source": "https://github.com/symfony/deprecation-contracts/tree/v2.5.2" }, "funding": [ { @@ -4823,20 +4792,20 @@ "type": "tidelift" } ], - "time": "2021-07-12T14:48:14+00:00" + "time": "2022-01-02T09:53:40+00:00" }, { "name": "symfony/polyfill-ctype", - "version": "v1.25.0", + "version": "v1.26.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-ctype.git", - "reference": "30885182c981ab175d4d034db0f6f469898070ab" + "reference": "6fd1b9a79f6e3cf65f9e679b23af304cd9e010d4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/30885182c981ab175d4d034db0f6f469898070ab", - "reference": "30885182c981ab175d4d034db0f6f469898070ab", + "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/6fd1b9a79f6e3cf65f9e679b23af304cd9e010d4", + "reference": "6fd1b9a79f6e3cf65f9e679b23af304cd9e010d4", "shasum": "" }, "require": { @@ -4851,7 +4820,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.23-dev" + "dev-main": "1.26-dev" }, "thanks": { "name": "symfony/polyfill", @@ -4889,7 +4858,7 @@ "portable" ], "support": { - "source": "https://github.com/symfony/polyfill-ctype/tree/v1.25.0" + "source": "https://github.com/symfony/polyfill-ctype/tree/v1.26.0" }, "funding": [ { @@ -4905,20 +4874,20 @@ "type": "tidelift" } ], - "time": "2021-10-20T20:35:02+00:00" + "time": "2022-05-24T11:49:31+00:00" }, { "name": "symfony/polyfill-intl-grapheme", - "version": "v1.25.0", + "version": "v1.26.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-grapheme.git", - "reference": "81b86b50cf841a64252b439e738e97f4a34e2783" + "reference": "433d05519ce6990bf3530fba6957499d327395c2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-intl-grapheme/zipball/81b86b50cf841a64252b439e738e97f4a34e2783", - "reference": "81b86b50cf841a64252b439e738e97f4a34e2783", + "url": "https://api.github.com/repos/symfony/polyfill-intl-grapheme/zipball/433d05519ce6990bf3530fba6957499d327395c2", + "reference": "433d05519ce6990bf3530fba6957499d327395c2", "shasum": "" }, "require": { @@ -4930,7 +4899,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.23-dev" + "dev-main": "1.26-dev" }, "thanks": { "name": "symfony/polyfill", @@ -4970,7 +4939,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-intl-grapheme/tree/v1.25.0" + "source": "https://github.com/symfony/polyfill-intl-grapheme/tree/v1.26.0" }, "funding": [ { @@ -4986,20 +4955,20 @@ "type": "tidelift" } ], - "time": "2021-11-23T21:10:46+00:00" + "time": "2022-05-24T11:49:31+00:00" }, { "name": "symfony/polyfill-intl-normalizer", - "version": "v1.25.0", + "version": "v1.26.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-normalizer.git", - "reference": "8590a5f561694770bdcd3f9b5c69dde6945028e8" + "reference": "219aa369ceff116e673852dce47c3a41794c14bd" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-intl-normalizer/zipball/8590a5f561694770bdcd3f9b5c69dde6945028e8", - "reference": "8590a5f561694770bdcd3f9b5c69dde6945028e8", + "url": "https://api.github.com/repos/symfony/polyfill-intl-normalizer/zipball/219aa369ceff116e673852dce47c3a41794c14bd", + "reference": "219aa369ceff116e673852dce47c3a41794c14bd", "shasum": "" }, "require": { @@ -5011,7 +4980,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.23-dev" + "dev-main": "1.26-dev" }, "thanks": { "name": "symfony/polyfill", @@ -5054,7 +5023,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-intl-normalizer/tree/v1.25.0" + "source": "https://github.com/symfony/polyfill-intl-normalizer/tree/v1.26.0" }, "funding": [ { @@ -5070,20 +5039,20 @@ "type": "tidelift" } ], - "time": "2021-02-19T12:13:01+00:00" + "time": "2022-05-24T11:49:31+00:00" }, { "name": "symfony/polyfill-mbstring", - "version": "v1.25.0", + "version": "v1.26.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-mbstring.git", - "reference": "0abb51d2f102e00a4eefcf46ba7fec406d245825" + "reference": "9344f9cb97f3b19424af1a21a3b0e75b0a7d8d7e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/0abb51d2f102e00a4eefcf46ba7fec406d245825", - "reference": "0abb51d2f102e00a4eefcf46ba7fec406d245825", + "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/9344f9cb97f3b19424af1a21a3b0e75b0a7d8d7e", + "reference": "9344f9cb97f3b19424af1a21a3b0e75b0a7d8d7e", "shasum": "" }, "require": { @@ -5098,7 +5067,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.23-dev" + "dev-main": "1.26-dev" }, "thanks": { "name": "symfony/polyfill", @@ -5137,7 +5106,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.25.0" + "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.26.0" }, "funding": [ { @@ -5153,20 +5122,20 @@ "type": "tidelift" } ], - "time": "2021-11-30T18:21:41+00:00" + "time": "2022-05-24T11:49:31+00:00" }, { "name": "symfony/polyfill-php73", - "version": "v1.25.0", + "version": "v1.26.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php73.git", - "reference": "cc5db0e22b3cb4111010e48785a97f670b350ca5" + "reference": "e440d35fa0286f77fb45b79a03fedbeda9307e85" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php73/zipball/cc5db0e22b3cb4111010e48785a97f670b350ca5", - "reference": "cc5db0e22b3cb4111010e48785a97f670b350ca5", + "url": "https://api.github.com/repos/symfony/polyfill-php73/zipball/e440d35fa0286f77fb45b79a03fedbeda9307e85", + "reference": "e440d35fa0286f77fb45b79a03fedbeda9307e85", "shasum": "" }, "require": { @@ -5175,7 +5144,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.23-dev" + "dev-main": "1.26-dev" }, "thanks": { "name": "symfony/polyfill", @@ -5216,7 +5185,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-php73/tree/v1.25.0" + "source": "https://github.com/symfony/polyfill-php73/tree/v1.26.0" }, "funding": [ { @@ -5232,20 +5201,20 @@ "type": "tidelift" } ], - "time": "2021-06-05T21:20:04+00:00" + "time": "2022-05-24T11:49:31+00:00" }, { "name": "symfony/polyfill-php80", - "version": "v1.25.0", + "version": "v1.26.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-php80.git", - "reference": "4407588e0d3f1f52efb65fbe92babe41f37fe50c" + "reference": "cfa0ae98841b9e461207c13ab093d76b0fa7bace" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/4407588e0d3f1f52efb65fbe92babe41f37fe50c", - "reference": "4407588e0d3f1f52efb65fbe92babe41f37fe50c", + "url": "https://api.github.com/repos/symfony/polyfill-php80/zipball/cfa0ae98841b9e461207c13ab093d76b0fa7bace", + "reference": "cfa0ae98841b9e461207c13ab093d76b0fa7bace", "shasum": "" }, "require": { @@ -5254,7 +5223,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.23-dev" + "dev-main": "1.26-dev" }, "thanks": { "name": "symfony/polyfill", @@ -5299,7 +5268,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-php80/tree/v1.25.0" + "source": "https://github.com/symfony/polyfill-php80/tree/v1.26.0" }, "funding": [ { @@ -5315,26 +5284,26 @@ "type": "tidelift" } ], - "time": "2022-03-04T08:16:47+00:00" + "time": "2022-05-10T07:21:04+00:00" }, { "name": "symfony/service-contracts", - "version": "v2.5.0", + "version": "v2.5.2", "source": { "type": "git", "url": "https://github.com/symfony/service-contracts.git", - "reference": "1ab11b933cd6bc5464b08e81e2c5b07dec58b0fc" + "reference": "4b426aac47d6427cc1a1d0f7e2ac724627f5966c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/service-contracts/zipball/1ab11b933cd6bc5464b08e81e2c5b07dec58b0fc", - "reference": "1ab11b933cd6bc5464b08e81e2c5b07dec58b0fc", + "url": "https://api.github.com/repos/symfony/service-contracts/zipball/4b426aac47d6427cc1a1d0f7e2ac724627f5966c", + "reference": "4b426aac47d6427cc1a1d0f7e2ac724627f5966c", "shasum": "" }, "require": { "php": ">=7.2.5", "psr/container": "^1.1", - "symfony/deprecation-contracts": "^2.1" + "symfony/deprecation-contracts": "^2.1|^3" }, "conflict": { "ext-psr": "<1.1|>=2" @@ -5382,7 +5351,7 @@ "standards" ], "support": { - "source": "https://github.com/symfony/service-contracts/tree/v2.5.0" + "source": "https://github.com/symfony/service-contracts/tree/v2.5.2" }, "funding": [ { @@ -5398,20 +5367,20 @@ "type": "tidelift" } ], - "time": "2021-11-04T16:48:04+00:00" + "time": "2022-05-30T19:17:29+00:00" }, { "name": "symfony/string", - "version": "v5.4.3", + "version": "v5.4.10", "source": { "type": "git", "url": "https://github.com/symfony/string.git", - "reference": "92043b7d8383e48104e411bc9434b260dbeb5a10" + "reference": "4432bc7df82a554b3e413a8570ce2fea90e94097" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/string/zipball/92043b7d8383e48104e411bc9434b260dbeb5a10", - "reference": "92043b7d8383e48104e411bc9434b260dbeb5a10", + "url": "https://api.github.com/repos/symfony/string/zipball/4432bc7df82a554b3e413a8570ce2fea90e94097", + "reference": "4432bc7df82a554b3e413a8570ce2fea90e94097", "shasum": "" }, "require": { @@ -5468,7 +5437,7 @@ "utf8" ], "support": { - "source": "https://github.com/symfony/string/tree/v5.4.3" + "source": "https://github.com/symfony/string/tree/v5.4.10" }, "funding": [ { @@ -5484,7 +5453,7 @@ "type": "tidelift" } ], - "time": "2022-01-02T09:53:40+00:00" + "time": "2022-06-26T15:57:47+00:00" }, { "name": "theseer/tokenizer", @@ -5538,16 +5507,16 @@ }, { "name": "vimeo/psalm", - "version": "4.22.0", + "version": "4.24.0", "source": { "type": "git", "url": "https://github.com/vimeo/psalm.git", - "reference": "fc2c6ab4d5fa5d644d8617089f012f3bb84b8703" + "reference": "06dd975cb55d36af80f242561738f16c5f58264f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/vimeo/psalm/zipball/fc2c6ab4d5fa5d644d8617089f012f3bb84b8703", - "reference": "fc2c6ab4d5fa5d644d8617089f012f3bb84b8703", + "url": "https://api.github.com/repos/vimeo/psalm/zipball/06dd975cb55d36af80f242561738f16c5f58264f", + "reference": "06dd975cb55d36af80f242561738f16c5f58264f", "shasum": "" }, "require": { @@ -5572,6 +5541,7 @@ "php": "^7.1|^8", "sebastian/diff": "^3.0 || ^4.0", "symfony/console": "^3.4.17 || ^4.1.6 || ^5.0 || ^6.0", + "symfony/polyfill-php80": "^1.25", "webmozart/path-util": "^2.3" }, "provide": { @@ -5638,9 +5608,9 @@ ], "support": { "issues": "https://github.com/vimeo/psalm/issues", - "source": "https://github.com/vimeo/psalm/tree/4.22.0" + "source": "https://github.com/vimeo/psalm/tree/4.24.0" }, - "time": "2022-02-24T20:34:05+00:00" + "time": "2022-06-26T11:47:54+00:00" }, { "name": "webimpress/coding-standard", @@ -5758,21 +5728,21 @@ }, { "name": "webmozart/assert", - "version": "1.10.0", + "version": "1.11.0", "source": { "type": "git", "url": "https://github.com/webmozarts/assert.git", - "reference": "6964c76c7804814a842473e0c8fd15bab0f18e25" + "reference": "11cb2199493b2f8a3b53e7f19068fc6aac760991" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/webmozarts/assert/zipball/6964c76c7804814a842473e0c8fd15bab0f18e25", - "reference": "6964c76c7804814a842473e0c8fd15bab0f18e25", + "url": "https://api.github.com/repos/webmozarts/assert/zipball/11cb2199493b2f8a3b53e7f19068fc6aac760991", + "reference": "11cb2199493b2f8a3b53e7f19068fc6aac760991", "shasum": "" }, "require": { - "php": "^7.2 || ^8.0", - "symfony/polyfill-ctype": "^1.8" + "ext-ctype": "*", + "php": "^7.2 || ^8.0" }, "conflict": { "phpstan/phpstan": "<0.12.20", @@ -5810,9 +5780,9 @@ ], "support": { "issues": "https://github.com/webmozarts/assert/issues", - "source": "https://github.com/webmozarts/assert/tree/1.10.0" + "source": "https://github.com/webmozarts/assert/tree/1.11.0" }, - "time": "2021-03-09T10:59:23+00:00" + "time": "2022-06-03T18:03:27+00:00" }, { "name": "webmozart/path-util", @@ -5881,5 +5851,5 @@ "platform-overrides": { "php": "7.4" }, - "plugin-api-version": "2.2.0" + "plugin-api-version": "2.3.0" } diff --git a/psalm-baseline.xml b/psalm-baseline.xml index 172d11226..e7debfbf7 100644 --- a/psalm-baseline.xml +++ b/psalm-baseline.xml @@ -1,5 +1,5 @@ - + $templatePath @@ -19,10 +19,7 @@ - - $closingBracket - $closingBracket - $closingBracket + $closingBracket $closingBracket $closingBracket @@ -194,6 +191,9 @@ HeadLink + + (object) $attributes + $args $args @@ -250,6 +250,9 @@ $value + + stdClass + $index @@ -525,7 +528,9 @@ $item $item - + + static fn($item) => $item + $item $separator @@ -550,28 +555,6 @@ translate - - - array - - - $escaper - $item - $item - - - $escaper($item) - - - $item - - - plugin - - - plugin - - is_array($content) @@ -635,66 +618,17 @@ - - null === $this->viewModelHelper - - - $viewModelHelper - - - $this->viewModelHelper - - - ViewModel - - - $this->viewModelHelper - - - getTemplate - plugin - setTemplate - (string) $template - - plugin - - - null === $this->plugins - - - false - call_user_func_array($helper, $arguments) ExceptionInterface - - $plugins - - - $helper - $helper - - - $helper - - - NavigationHelper - - - setContainer - setContainer - - - $helper - $container @@ -708,12 +642,6 @@ $view $view - - $helper - $helper - $this->plugins - $view && $this->plugins - hasTranslator setTranslator @@ -757,8 +685,7 @@ $page->getTextDomain() $page->getTextDomain() - - $container + $container $container $label @@ -1262,12 +1189,11 @@ $this->items - + (string) $key (string) $key (string) $key (string) $key - (string) $name @@ -1471,11 +1397,6 @@ (bool) $useProxy - - - $cName - - $config['view_helper_config']['doctype'] @@ -1509,12 +1430,6 @@ $options - - - $current - $root - - ! $events @@ -1540,9 +1455,6 @@ has has - - $aliases - $this->initializers @@ -1702,17 +1614,13 @@ - + gettype($helpers) gettype($variables) - is_callable($plugin) $values - - HelperPluginManager - $__vars $this->__template @@ -1746,11 +1654,7 @@ clone $this->vars() - - call_user_func_array($plugin, $argv) - - - AbstractHelper + string string|Resolver @@ -1763,8 +1667,7 @@ $this->__templateResolver->resolve($name, $this) $this->getHelperPluginManager()->get($name, $options) - - $this->__helpers + $this->__templateResolver @@ -1793,9 +1696,6 @@ is_object($helpers) is_object($variables) - - setCurrent - include $this->__file @@ -1864,7 +1764,6 @@ $value $value $value - $value $this->lastLookupFailure @@ -1875,7 +1774,6 @@ $this->paths - (bool) $flag (bool) $flag (string) $defaultSuffix @@ -2271,9 +2169,6 @@ $values $values - - setCharset - $attributeEscaper('boo bah') $attributeEscaper('foo bar') @@ -2310,35 +2205,6 @@ offsetSetName setIndent - - __invoke - __invoke - __invoke - __invoke - __invoke - __invoke - __invoke - appendHttpEquiv - appendHttpEquiv - appendHttpEquiv - appendHttpEquiv - setCharset - setCharset - setCharset - setName - setName - setName - setName - setName - setName - setProperty - toString - toString - toString - toString - toString - toString - @@ -2417,10 +2283,6 @@ setIndent setIndent - - setDoctype - setDoctype - @@ -2446,9 +2308,6 @@ $values[2] - $item - $item - $item $item $item $value @@ -2459,9 +2318,6 @@ $values - $item->content - $item->content - $item->content $item->content $item->content $value->attributes @@ -2491,18 +2347,6 @@ renderTitle - - - false - false - - - - - __invoke - __invoke - - $escape($value) @@ -2510,11 +2354,6 @@ $escape('http://www.w3.org/1999/xhtml') - - - setTemplate - - $acl @@ -2706,15 +2545,11 @@ getLabel getLabel - + getHref getLabel getLabel - plugin - - plugin - $discard $discard @@ -2769,6 +2604,9 @@ $this->errorHandlerMessage + + PsrContainerDecorator + $code @@ -2798,6 +2636,7 @@ $nav = clone $this->nav2; $nav->addPage(['label' => 'Invalid', 'uri' => 'http://w.']); + static::fail('A Laminas\View\Exception\InvalidArgumentException was not thrown on invalid <loc />'); @@ -3071,26 +2910,20 @@ $serviceConfig $test $test - $test $urlHelper $urlHelper - $urlHelper - $viewHelpers $viewHelpers $viewHelpers - $urlHelper('test') $urlHelper('test') $urlHelper('test', [], ['force_canonical' => true]) - bootstrap bootstrap bootstrap get get - get setRequestUri @@ -3106,13 +2939,8 @@ - - $this->getServiceNotFoundException() - $this->getServiceNotFoundException() - $target - $target $alias @@ -3128,12 +2956,7 @@ $container $container - - $helper - $helper - $helper - $helper - $helper + $helperB @@ -3191,10 +3014,6 @@ $vars - - getCurrent - hasCurrent - $errno $errstr @@ -3303,8 +3122,7 @@ - - $e + $e $e $e @@ -3336,8 +3154,7 @@ null - - $e + $e $e $e diff --git a/src/Helper/Json.php b/src/Helper/Json.php index f00489add..542119922 100644 --- a/src/Helper/Json.php +++ b/src/Helper/Json.php @@ -32,8 +32,8 @@ class Json extends AbstractHelper * Encode data as JSON and set response header * * @param mixed $data - * @param array $jsonOptions Options to pass to JsonFormatter::encode() - * @return string|void + * @param array{prettyPrint?: bool} $jsonOptions Options to pass to JsonFormatter::encode() + * @return string */ public function __invoke($data, array $jsonOptions = []) { diff --git a/test/Helper/Service/IdentityFactoryTest.php b/test/Helper/Service/IdentityFactoryTest.php index 581a3c3e6..e8685ccb0 100644 --- a/test/Helper/Service/IdentityFactoryTest.php +++ b/test/Helper/Service/IdentityFactoryTest.php @@ -4,7 +4,7 @@ namespace LaminasTest\View\Helper\Service; -use Interop\Container\ContainerInterface; +use Interop\Container\ContainerInterface; // phpcs:ignore use Laminas\Authentication\AuthenticationService; use Laminas\Authentication\AuthenticationServiceInterface; use Laminas\View\Exception\RuntimeException; From f4e55c7f36dbf5db47c208f52196516ea7706c7c Mon Sep 17 00:00:00 2001 From: "renovate[bot]" <29139614+renovate[bot]@users.noreply.github.com> Date: Wed, 24 Aug 2022 23:06:37 +0000 Subject: [PATCH 24/58] Update dependency laminas/laminas-coding-standard to ~2.4.0 | datasource | package | from | to | | ---------- | ------------------------------- | ----- | ----- | | packagist | laminas/laminas-coding-standard | 2.3.0 | 2.4.0 | Signed-off-by: Renovate Bot --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 793f32303..db380bfe9 100644 --- a/composer.json +++ b/composer.json @@ -40,7 +40,7 @@ }, "require-dev": { "laminas/laminas-authentication": "^2.5", - "laminas/laminas-coding-standard": "~2.3.0", + "laminas/laminas-coding-standard": "~2.4.0", "laminas/laminas-feed": "^2.15", "laminas/laminas-filter": "^2.13.0", "laminas/laminas-http": "^2.15", From 54bf1bf6e1a1c3b50814c1220447ab9d4b8b5379 Mon Sep 17 00:00:00 2001 From: Marco Pivetta Date: Thu, 25 Aug 2022 02:16:12 +0200 Subject: [PATCH 25/58] Upgraded PHPUnit, laminas/laminas-coding-standard and removed prophecy transitive dependency --- composer.json | 4 +- composer.lock | 175 +++++++++++++++----------------------------------- 2 files changed, 55 insertions(+), 124 deletions(-) diff --git a/composer.json b/composer.json index db380bfe9..ec00ff553 100644 --- a/composer.json +++ b/composer.json @@ -40,7 +40,7 @@ }, "require-dev": { "laminas/laminas-authentication": "^2.5", - "laminas/laminas-coding-standard": "~2.4.0", + "laminas/laminas-coding-standard": "^2.4.0", "laminas/laminas-feed": "^2.15", "laminas/laminas-filter": "^2.13.0", "laminas/laminas-http": "^2.15", @@ -53,7 +53,7 @@ "laminas/laminas-permissions-acl": "^2.6", "laminas/laminas-router": "^3.0.1", "laminas/laminas-uri": "^2.5", - "phpunit/phpunit": "^9.5.5", + "phpunit/phpunit": "^9.5.23", "psalm/plugin-phpunit": "^0.17.0", "vimeo/psalm": "^4.10" }, diff --git a/composer.lock b/composer.lock index 1eeb5e6bd..d06ce6272 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "f636204767b9525986897d0dc7ef0038", + "content-hash": "74310b0c07b0f7b018b00e8674a4ad57", "packages": [ { "name": "laminas/laminas-escaper", @@ -1263,25 +1263,28 @@ }, { "name": "laminas/laminas-coding-standard", - "version": "2.3.0", + "version": "2.4.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-coding-standard.git", - "reference": "bcf6e07fe4690240be7beb6d884d0b0fafa6a251" + "reference": "eb076dd86aa93dd424856b150c9b6f76c1fdfabc" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-coding-standard/zipball/bcf6e07fe4690240be7beb6d884d0b0fafa6a251", - "reference": "bcf6e07fe4690240be7beb6d884d0b0fafa6a251", + "url": "https://api.github.com/repos/laminas/laminas-coding-standard/zipball/eb076dd86aa93dd424856b150c9b6f76c1fdfabc", + "reference": "eb076dd86aa93dd424856b150c9b6f76c1fdfabc", "shasum": "" }, "require": { "dealerdirect/phpcodesniffer-composer-installer": "^0.7", - "php": "^7.3 || ^8.0", + "php": "^7.4 || ^8.0", "slevomat/coding-standard": "^7.0", "squizlabs/php_codesniffer": "^3.6", "webimpress/coding-standard": "^1.2" }, + "conflict": { + "phpstan/phpdoc-parser": ">=1.6.0" + }, "type": "phpcodesniffer-standard", "autoload": { "psr-4": { @@ -1312,7 +1315,7 @@ "type": "community_bridge" } ], - "time": "2021-05-29T15:53:59+00:00" + "time": "2022-08-24T17:45:47+00:00" }, { "name": "laminas/laminas-config", @@ -2905,85 +2908,18 @@ }, "time": "2022-03-15T21:29:03+00:00" }, - { - "name": "phpspec/prophecy", - "version": "v1.15.0", - "source": { - "type": "git", - "url": "https://github.com/phpspec/prophecy.git", - "reference": "bbcd7380b0ebf3961ee21409db7b38bc31d69a13" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/phpspec/prophecy/zipball/bbcd7380b0ebf3961ee21409db7b38bc31d69a13", - "reference": "bbcd7380b0ebf3961ee21409db7b38bc31d69a13", - "shasum": "" - }, - "require": { - "doctrine/instantiator": "^1.2", - "php": "^7.2 || ~8.0, <8.2", - "phpdocumentor/reflection-docblock": "^5.2", - "sebastian/comparator": "^3.0 || ^4.0", - "sebastian/recursion-context": "^3.0 || ^4.0" - }, - "require-dev": { - "phpspec/phpspec": "^6.0 || ^7.0", - "phpunit/phpunit": "^8.0 || ^9.0" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.x-dev" - } - }, - "autoload": { - "psr-4": { - "Prophecy\\": "src/Prophecy" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Konstantin Kudryashov", - "email": "ever.zet@gmail.com", - "homepage": "http://everzet.com" - }, - { - "name": "Marcello Duarte", - "email": "marcello.duarte@gmail.com" - } - ], - "description": "Highly opinionated mocking framework for PHP 5.3+", - "homepage": "https://github.com/phpspec/prophecy", - "keywords": [ - "Double", - "Dummy", - "fake", - "mock", - "spy", - "stub" - ], - "support": { - "issues": "https://github.com/phpspec/prophecy/issues", - "source": "https://github.com/phpspec/prophecy/tree/v1.15.0" - }, - "time": "2021-12-08T12:19:24+00:00" - }, { "name": "phpstan/phpdoc-parser", - "version": "1.6.4", + "version": "1.5.1", "source": { "type": "git", "url": "https://github.com/phpstan/phpdoc-parser.git", - "reference": "135607f9ccc297d6923d49c2bcf309f509413215" + "reference": "981cc368a216c988e862a75e526b6076987d1b50" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/phpstan/phpdoc-parser/zipball/135607f9ccc297d6923d49c2bcf309f509413215", - "reference": "135607f9ccc297d6923d49c2bcf309f509413215", + "url": "https://api.github.com/repos/phpstan/phpdoc-parser/zipball/981cc368a216c988e862a75e526b6076987d1b50", + "reference": "981cc368a216c988e862a75e526b6076987d1b50", "shasum": "" }, "require": { @@ -2993,7 +2929,6 @@ "php-parallel-lint/php-parallel-lint": "^1.2", "phpstan/extension-installer": "^1.0", "phpstan/phpstan": "^1.5", - "phpstan/phpstan-phpunit": "^1.1", "phpstan/phpstan-strict-rules": "^1.0", "phpunit/phpunit": "^9.5", "symfony/process": "^5.2" @@ -3013,29 +2948,29 @@ "description": "PHPDoc parser with support for nullable, intersection and generic types", "support": { "issues": "https://github.com/phpstan/phpdoc-parser/issues", - "source": "https://github.com/phpstan/phpdoc-parser/tree/1.6.4" + "source": "https://github.com/phpstan/phpdoc-parser/tree/1.5.1" }, - "time": "2022-06-26T13:09:08+00:00" + "time": "2022-05-05T11:32:40+00:00" }, { "name": "phpunit/php-code-coverage", - "version": "9.2.15", + "version": "9.2.16", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "2e9da11878c4202f97915c1cb4bb1ca318a63f5f" + "reference": "2593003befdcc10db5e213f9f28814f5aa8ac073" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/2e9da11878c4202f97915c1cb4bb1ca318a63f5f", - "reference": "2e9da11878c4202f97915c1cb4bb1ca318a63f5f", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/2593003befdcc10db5e213f9f28814f5aa8ac073", + "reference": "2593003befdcc10db5e213f9f28814f5aa8ac073", "shasum": "" }, "require": { "ext-dom": "*", "ext-libxml": "*", "ext-xmlwriter": "*", - "nikic/php-parser": "^4.13.0", + "nikic/php-parser": "^4.14", "php": ">=7.3", "phpunit/php-file-iterator": "^3.0.3", "phpunit/php-text-template": "^2.0.2", @@ -3084,7 +3019,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", - "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.15" + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.16" }, "funding": [ { @@ -3092,7 +3027,7 @@ "type": "github" } ], - "time": "2022-03-07T09:28:20+00:00" + "time": "2022-08-20T05:26:47+00:00" }, { "name": "phpunit/php-file-iterator", @@ -3337,16 +3272,16 @@ }, { "name": "phpunit/phpunit", - "version": "9.5.21", + "version": "9.5.23", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "0e32b76be457de00e83213528f6bb37e2a38fcb1" + "reference": "888556852e7e9bbeeedb9656afe46118765ade34" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/0e32b76be457de00e83213528f6bb37e2a38fcb1", - "reference": "0e32b76be457de00e83213528f6bb37e2a38fcb1", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/888556852e7e9bbeeedb9656afe46118765ade34", + "reference": "888556852e7e9bbeeedb9656afe46118765ade34", "shasum": "" }, "require": { @@ -3361,7 +3296,6 @@ "phar-io/manifest": "^2.0.3", "phar-io/version": "^3.0.2", "php": ">=7.3", - "phpspec/prophecy": "^1.12.1", "phpunit/php-code-coverage": "^9.2.13", "phpunit/php-file-iterator": "^3.0.5", "phpunit/php-invoker": "^3.1.1", @@ -3379,9 +3313,6 @@ "sebastian/type": "^3.0", "sebastian/version": "^3.0.2" }, - "require-dev": { - "phpspec/prophecy-phpunit": "^2.0.1" - }, "suggest": { "ext-soap": "*", "ext-xdebug": "*" @@ -3423,7 +3354,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", - "source": "https://github.com/sebastianbergmann/phpunit/tree/9.5.21" + "source": "https://github.com/sebastianbergmann/phpunit/tree/9.5.23" }, "funding": [ { @@ -3435,20 +3366,20 @@ "type": "github" } ], - "time": "2022-06-19T12:14:25+00:00" + "time": "2022-08-22T14:01:36+00:00" }, { "name": "psalm/plugin-phpunit", - "version": "0.16.1", + "version": "0.17.0", "source": { "type": "git", "url": "https://github.com/psalm/psalm-plugin-phpunit.git", - "reference": "5dd3be04f37a857d52880ef6af2524a441dfef24" + "reference": "45951541beef07e93e3ad197daf01da88e85c31d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/psalm/psalm-plugin-phpunit/zipball/5dd3be04f37a857d52880ef6af2524a441dfef24", - "reference": "5dd3be04f37a857d52880ef6af2524a441dfef24", + "url": "https://api.github.com/repos/psalm/psalm-plugin-phpunit/zipball/45951541beef07e93e3ad197daf01da88e85c31d", + "reference": "45951541beef07e93e3ad197daf01da88e85c31d", "shasum": "" }, "require": { @@ -3493,9 +3424,9 @@ "description": "Psalm plugin for PHPUnit", "support": { "issues": "https://github.com/psalm/psalm-plugin-phpunit/issues", - "source": "https://github.com/psalm/psalm-plugin-phpunit/tree/0.16.1" + "source": "https://github.com/psalm/psalm-plugin-phpunit/tree/0.17.0" }, - "time": "2021-06-18T23:56:46+00:00" + "time": "2022-06-14T17:05:57+00:00" }, { "name": "psr/log", @@ -4630,16 +4561,16 @@ }, { "name": "symfony/console", - "version": "v5.4.10", + "version": "v5.4.11", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "4d671ab4ddac94ee439ea73649c69d9d200b5000" + "reference": "535846c7ee6bc4dd027ca0d93220601456734b10" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/4d671ab4ddac94ee439ea73649c69d9d200b5000", - "reference": "4d671ab4ddac94ee439ea73649c69d9d200b5000", + "url": "https://api.github.com/repos/symfony/console/zipball/535846c7ee6bc4dd027ca0d93220601456734b10", + "reference": "535846c7ee6bc4dd027ca0d93220601456734b10", "shasum": "" }, "require": { @@ -4709,7 +4640,7 @@ "terminal" ], "support": { - "source": "https://github.com/symfony/console/tree/v5.4.10" + "source": "https://github.com/symfony/console/tree/v5.4.11" }, "funding": [ { @@ -4725,7 +4656,7 @@ "type": "tidelift" } ], - "time": "2022-06-26T13:00:04+00:00" + "time": "2022-07-22T10:42:43+00:00" }, { "name": "symfony/deprecation-contracts", @@ -5371,16 +5302,16 @@ }, { "name": "symfony/string", - "version": "v5.4.10", + "version": "v5.4.11", "source": { "type": "git", "url": "https://github.com/symfony/string.git", - "reference": "4432bc7df82a554b3e413a8570ce2fea90e94097" + "reference": "5eb661e49ad389e4ae2b6e4df8d783a8a6548322" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/string/zipball/4432bc7df82a554b3e413a8570ce2fea90e94097", - "reference": "4432bc7df82a554b3e413a8570ce2fea90e94097", + "url": "https://api.github.com/repos/symfony/string/zipball/5eb661e49ad389e4ae2b6e4df8d783a8a6548322", + "reference": "5eb661e49ad389e4ae2b6e4df8d783a8a6548322", "shasum": "" }, "require": { @@ -5437,7 +5368,7 @@ "utf8" ], "support": { - "source": "https://github.com/symfony/string/tree/v5.4.10" + "source": "https://github.com/symfony/string/tree/v5.4.11" }, "funding": [ { @@ -5453,7 +5384,7 @@ "type": "tidelift" } ], - "time": "2022-06-26T15:57:47+00:00" + "time": "2022-07-24T16:15:25+00:00" }, { "name": "theseer/tokenizer", @@ -5507,16 +5438,16 @@ }, { "name": "vimeo/psalm", - "version": "4.24.0", + "version": "4.26.0", "source": { "type": "git", "url": "https://github.com/vimeo/psalm.git", - "reference": "06dd975cb55d36af80f242561738f16c5f58264f" + "reference": "6998fabb2bf528b65777bf9941920888d23c03ac" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/vimeo/psalm/zipball/06dd975cb55d36af80f242561738f16c5f58264f", - "reference": "06dd975cb55d36af80f242561738f16c5f58264f", + "url": "https://api.github.com/repos/vimeo/psalm/zipball/6998fabb2bf528b65777bf9941920888d23c03ac", + "reference": "6998fabb2bf528b65777bf9941920888d23c03ac", "shasum": "" }, "require": { @@ -5608,9 +5539,9 @@ ], "support": { "issues": "https://github.com/vimeo/psalm/issues", - "source": "https://github.com/vimeo/psalm/tree/4.24.0" + "source": "https://github.com/vimeo/psalm/tree/4.26.0" }, - "time": "2022-06-26T11:47:54+00:00" + "time": "2022-07-31T13:10:26+00:00" }, { "name": "webimpress/coding-standard", From c42ef1a95b351987612c7f591d87bc2e285214f2 Mon Sep 17 00:00:00 2001 From: George Steel Date: Tue, 11 Oct 2022 18:02:33 +0100 Subject: [PATCH 26/58] Refresh lock file post merge-up Signed-off-by: George Steel --- composer.json | 28 +- composer.lock | 716 ++++++++++++++++++++++---------------------------- 2 files changed, 334 insertions(+), 410 deletions(-) diff --git a/composer.json b/composer.json index 83b2f4cfe..292585f3f 100644 --- a/composer.json +++ b/composer.json @@ -39,21 +39,21 @@ "psr/container": "^1 || ^2" }, "require-dev": { - "laminas/laminas-authentication": "^2.5", + "laminas/laminas-authentication": "^2.12", "laminas/laminas-coding-standard": "^2.4.0", - "laminas/laminas-feed": "^2.15", - "laminas/laminas-filter": "^2.13.0", - "laminas/laminas-http": "^2.15", - "laminas/laminas-i18n": "^2.6", - "laminas/laminas-modulemanager": "^2.7.1", - "laminas/laminas-mvc": "^3.0", - "laminas/laminas-mvc-i18n": "^1.1", - "laminas/laminas-navigation": "^2.13.1", - "laminas/laminas-paginator": "^2.11.0", - "laminas/laminas-permissions-acl": "^2.6", - "laminas/laminas-router": "^3.0.1", - "laminas/laminas-uri": "^2.5", - "phpunit/phpunit": "^9.5.23", + "laminas/laminas-feed": "^2.18.2", + "laminas/laminas-filter": "^2.23", + "laminas/laminas-http": "^2.16", + "laminas/laminas-i18n": "^2.19", + "laminas/laminas-modulemanager": "^2.12", + "laminas/laminas-mvc": "^3.3.5", + "laminas/laminas-mvc-i18n": "^1.4", + "laminas/laminas-navigation": "^2.15", + "laminas/laminas-paginator": "^2.13", + "laminas/laminas-permissions-acl": "^2.10", + "laminas/laminas-router": "^3.10", + "laminas/laminas-uri": "^2.9.1", + "phpunit/phpunit": "^9.5.25", "psalm/plugin-phpunit": "^0.17.0", "vimeo/psalm": "^4.28" }, diff --git a/composer.lock b/composer.lock index d06ce6272..322453b9e 100644 --- a/composer.lock +++ b/composer.lock @@ -4,36 +4,36 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "74310b0c07b0f7b018b00e8674a4ad57", + "content-hash": "0037e980d689f083fe83c3e181d93e64", "packages": [ { "name": "laminas/laminas-escaper", - "version": "2.10.0", + "version": "2.12.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-escaper.git", - "reference": "58af67282db37d24e584a837a94ee55b9c7552be" + "reference": "ee7a4c37bf3d0e8c03635d5bddb5bb3184ead490" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-escaper/zipball/58af67282db37d24e584a837a94ee55b9c7552be", - "reference": "58af67282db37d24e584a837a94ee55b9c7552be", + "url": "https://api.github.com/repos/laminas/laminas-escaper/zipball/ee7a4c37bf3d0e8c03635d5bddb5bb3184ead490", + "reference": "ee7a4c37bf3d0e8c03635d5bddb5bb3184ead490", "shasum": "" }, "require": { "ext-ctype": "*", "ext-mbstring": "*", - "php": "^7.4 || ~8.0.0 || ~8.1.0" + "php": "^7.4 || ~8.0.0 || ~8.1.0 || ~8.2.0" }, "conflict": { "zendframework/zend-escaper": "*" }, "require-dev": { "infection/infection": "^0.26.6", - "laminas/laminas-coding-standard": "~2.3.0", + "laminas/laminas-coding-standard": "~2.4.0", "maglnet/composer-require-checker": "^3.8.0", "phpunit/phpunit": "^9.5.18", - "psalm/plugin-phpunit": "^0.16.1", + "psalm/plugin-phpunit": "^0.17.0", "vimeo/psalm": "^4.22.0" }, "type": "library", @@ -66,36 +66,37 @@ "type": "community_bridge" } ], - "time": "2022-03-08T20:15:36+00:00" + "time": "2022-10-10T10:11:09+00:00" }, { "name": "laminas/laminas-eventmanager", - "version": "3.5.0", + "version": "3.6.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-eventmanager.git", - "reference": "41f7209428f37cab9573365e361f4078209aaafa" + "reference": "3f1afbad86cd34a431fdc069f265cfe6f8fc8308" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-eventmanager/zipball/41f7209428f37cab9573365e361f4078209aaafa", - "reference": "41f7209428f37cab9573365e361f4078209aaafa", + "url": "https://api.github.com/repos/laminas/laminas-eventmanager/zipball/3f1afbad86cd34a431fdc069f265cfe6f8fc8308", + "reference": "3f1afbad86cd34a431fdc069f265cfe6f8fc8308", "shasum": "" }, "require": { - "php": "^7.4 || ~8.0.0 || ~8.1.0" + "php": "~8.0.0 || ~8.1.0 || ~8.2.0" }, "conflict": { "container-interop/container-interop": "<1.2", "zendframework/zend-eventmanager": "*" }, "require-dev": { - "laminas/laminas-coding-standard": "~2.2.1", - "laminas/laminas-stdlib": "^3.6", - "phpbench/phpbench": "^1.1", - "phpspec/prophecy-phpunit": "^2.0", - "phpunit/phpunit": "^9.5.5", - "psr/container": "^1.1.2 || ^2.0.2" + "laminas/laminas-coding-standard": "~2.4.0", + "laminas/laminas-stdlib": "^3.15", + "phpbench/phpbench": "^1.2.6", + "phpunit/phpunit": "^9.5.25", + "psalm/plugin-phpunit": "^0.17.0", + "psr/container": "^1.1.2 || ^2.0.2", + "vimeo/psalm": "^4.28" }, "suggest": { "laminas/laminas-stdlib": "^2.7.3 || ^3.0, to use the FilterChain feature", @@ -133,7 +134,7 @@ "type": "community_bridge" } ], - "time": "2022-04-06T21:05:17+00:00" + "time": "2022-10-11T12:46:13+00:00" }, { "name": "laminas/laminas-json", @@ -198,21 +199,21 @@ }, { "name": "laminas/laminas-servicemanager", - "version": "3.14.0", + "version": "3.19.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-servicemanager.git", - "reference": "918de970b2c3d42acebff3d431d76db52b6a32a2" + "reference": "ed160729bb8721127efdaac799f9a298963345b1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-servicemanager/zipball/918de970b2c3d42acebff3d431d76db52b6a32a2", - "reference": "918de970b2c3d42acebff3d431d76db52b6a32a2", + "url": "https://api.github.com/repos/laminas/laminas-servicemanager/zipball/ed160729bb8721127efdaac799f9a298963345b1", + "reference": "ed160729bb8721127efdaac799f9a298963345b1", "shasum": "" }, "require": { "laminas/laminas-stdlib": "^3.2.1", - "php": "~7.4.0 || ~8.0.0 || ~8.1.0", + "php": "~8.0.0 || ~8.1.0 || ~8.2.0", "psr/container": "^1.0" }, "conflict": { @@ -228,17 +229,16 @@ "container-interop/container-interop": "^1.2.0" }, "require-dev": { - "composer/package-versions-deprecated": "^1.0", - "laminas/laminas-coding-standard": "~2.3.0", - "laminas/laminas-container-config-test": "^0.6", - "laminas/laminas-dependency-plugin": "^2.1.2", - "mikey179/vfsstream": "^1.6.10@alpha", - "ocramius/proxy-manager": "^2.11", - "phpbench/phpbench": "^1.1", - "phpspec/prophecy-phpunit": "^2.0", - "phpunit/phpunit": "^9.5.5", + "composer/package-versions-deprecated": "^1.11.99.5", + "laminas/laminas-coding-standard": "~2.4.0", + "laminas/laminas-container-config-test": "^0.7", + "laminas/laminas-dependency-plugin": "^2.2", + "mikey179/vfsstream": "^1.6.11@alpha", + "ocramius/proxy-manager": "^2.14.1", + "phpbench/phpbench": "^1.2.6", + "phpunit/phpunit": "^9.5.25", "psalm/plugin-phpunit": "^0.17.0", - "vimeo/psalm": "^4.8" + "vimeo/psalm": "^4.28" }, "suggest": { "ocramius/proxy-manager": "ProxyManager ^2.1.1 to handle lazy initialization of services" @@ -285,34 +285,34 @@ "type": "community_bridge" } ], - "time": "2022-07-07T16:13:26+00:00" + "time": "2022-10-10T20:59:22+00:00" }, { "name": "laminas/laminas-stdlib", - "version": "3.10.1", + "version": "3.15.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-stdlib.git", - "reference": "0d669074845fc80a99add0f64025192f143ef836" + "reference": "63b66bd4b696f024f42616b9d95cdb10e5109c27" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-stdlib/zipball/0d669074845fc80a99add0f64025192f143ef836", - "reference": "0d669074845fc80a99add0f64025192f143ef836", + "url": "https://api.github.com/repos/laminas/laminas-stdlib/zipball/63b66bd4b696f024f42616b9d95cdb10e5109c27", + "reference": "63b66bd4b696f024f42616b9d95cdb10e5109c27", "shasum": "" }, "require": { - "php": "^7.3 || ~8.0.0 || ~8.1.0" + "php": "~8.0.0 || ~8.1.0 || ~8.2.0" }, "conflict": { "zendframework/zend-stdlib": "*" }, "require-dev": { - "laminas/laminas-coding-standard": "~2.3.0", - "phpbench/phpbench": "^1.0", - "phpunit/phpunit": "^9.3.7", - "psalm/plugin-phpunit": "^0.16.0", - "vimeo/psalm": "^4.7" + "laminas/laminas-coding-standard": "^2.4.0", + "phpbench/phpbench": "^1.2.6", + "phpunit/phpunit": "^9.5.25", + "psalm/plugin-phpunit": "^0.17.0", + "vimeo/psalm": "^4.28" }, "type": "library", "autoload": { @@ -344,7 +344,7 @@ "type": "community_bridge" } ], - "time": "2022-06-10T14:49:09+00:00" + "time": "2022-10-10T19:10:24+00:00" }, { "name": "psr/container", @@ -1187,38 +1187,38 @@ }, { "name": "laminas/laminas-authentication", - "version": "2.11.0", + "version": "2.12.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-authentication.git", - "reference": "51815691d862b82b749a4aa9c4f6ec078d579f74" + "reference": "ecb59c6d7f7d0ed39790264ca16a94636cac98ae" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-authentication/zipball/51815691d862b82b749a4aa9c4f6ec078d579f74", - "reference": "51815691d862b82b749a4aa9c4f6ec078d579f74", + "url": "https://api.github.com/repos/laminas/laminas-authentication/zipball/ecb59c6d7f7d0ed39790264ca16a94636cac98ae", + "reference": "ecb59c6d7f7d0ed39790264ca16a94636cac98ae", "shasum": "" }, "require": { - "laminas/laminas-stdlib": "^3.2.1", - "php": "^7.3 || ~8.0.0 || ~8.1.0" + "laminas/laminas-stdlib": "^3.6.0", + "php": "^7.4 || ~8.0.0 || ~8.1.0" }, "conflict": { "zendframework/zend-authentication": "*" }, "require-dev": { - "laminas/laminas-coding-standard": "~2.3.0", - "laminas/laminas-crypt": "^2.6 || ^3.2.1", - "laminas/laminas-db": "^2.13", + "laminas/laminas-coding-standard": "~2.4.0", + "laminas/laminas-crypt": "^2.6.0 || ^3.2.1", + "laminas/laminas-db": "^2.13.0", "laminas/laminas-http": "^2.15.0", - "laminas/laminas-ldap": "^2.12", - "laminas/laminas-session": "^2.12", - "laminas/laminas-uri": "^2.5.2", - "laminas/laminas-validator": "^2.10.1", - "phpunit/phpunit": "^9.3", + "laminas/laminas-ldap": "^2.12.0", + "laminas/laminas-session": "^2.12.0", + "laminas/laminas-uri": "^2.9.1", + "laminas/laminas-validator": "^2.15.0", + "phpunit/phpunit": "^9.3.4", "psalm/plugin-phpunit": "^0.15.1", - "squizlabs/php_codesniffer": "^2.9.2 || ^3.6", - "vimeo/psalm": "^4.6" + "squizlabs/php_codesniffer": "^3.6.0", + "vimeo/psalm": "^4.6.0" }, "suggest": { "laminas/laminas-crypt": "Laminas\\Crypt component", @@ -1259,7 +1259,7 @@ "type": "community_bridge" } ], - "time": "2022-06-23T10:41:36+00:00" + "time": "2022-09-12T18:40:34+00:00" }, { "name": "laminas/laminas-coding-standard", @@ -1387,40 +1387,41 @@ }, { "name": "laminas/laminas-feed", - "version": "2.17.0", + "version": "2.18.2", "source": { "type": "git", "url": "https://github.com/laminas/laminas-feed.git", - "reference": "1ccb024ea615606ed1d676ba0fa3f22a398f3ac0" + "reference": "a57fdb9df42950d5b7f052509fbdab0d081c6b6d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-feed/zipball/1ccb024ea615606ed1d676ba0fa3f22a398f3ac0", - "reference": "1ccb024ea615606ed1d676ba0fa3f22a398f3ac0", + "url": "https://api.github.com/repos/laminas/laminas-feed/zipball/a57fdb9df42950d5b7f052509fbdab0d081c6b6d", + "reference": "a57fdb9df42950d5b7f052509fbdab0d081c6b6d", "shasum": "" }, "require": { "ext-dom": "*", "ext-libxml": "*", "laminas/laminas-escaper": "^2.9", + "laminas/laminas-servicemanager": "^3.14.0", "laminas/laminas-stdlib": "^3.6", - "php": "^7.3 || ~8.0.0 || ~8.1.0" + "php": "^7.4 || ~8.0.0 || ~8.1.0" }, "conflict": { "laminas/laminas-servicemanager": "<3.3", "zendframework/zend-feed": "*" }, "require-dev": { - "laminas/laminas-cache": "^2.7.2", - "laminas/laminas-coding-standard": "~2.2.1", + "laminas/laminas-cache": "^2.13.2 || ^3.1.3", + "laminas/laminas-cache-storage-adapter-memory": "^1.1.0 || ^2.0.0", + "laminas/laminas-coding-standard": "~2.3.0", "laminas/laminas-db": "^2.13.3", "laminas/laminas-http": "^2.15", - "laminas/laminas-servicemanager": "^3.7", "laminas/laminas-validator": "^2.15", "phpunit/phpunit": "^9.5.5", - "psalm/plugin-phpunit": "^0.13.0", + "psalm/plugin-phpunit": "^0.17.0", "psr/http-message": "^1.0.1", - "vimeo/psalm": "^4.1" + "vimeo/psalm": "^4.24.0" }, "suggest": { "laminas/laminas-cache": "Laminas\\Cache component, for optionally caching feeds between requests", @@ -1440,11 +1441,13 @@ "license": [ "BSD-3-Clause" ], - "description": "provides functionality for consuming RSS and Atom feeds", + "description": "provides functionality for creating and consuming RSS and Atom feeds", "homepage": "https://laminas.dev", "keywords": [ + "atom", "feed", - "laminas" + "laminas", + "rss" ], "support": { "chat": "https://laminas.dev/chat", @@ -1460,46 +1463,45 @@ "type": "community_bridge" } ], - "time": "2022-03-24T10:26:04+00:00" + "time": "2022-08-08T17:02:35+00:00" }, { "name": "laminas/laminas-filter", - "version": "2.14.0", + "version": "2.23.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-filter.git", - "reference": "98a126b8cd069a446054680c9be5f37a61f6dc17" + "reference": "41cff2f850753f0bb3fc75c5ce011fcad6aa1731" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-filter/zipball/98a126b8cd069a446054680c9be5f37a61f6dc17", - "reference": "98a126b8cd069a446054680c9be5f37a61f6dc17", + "url": "https://api.github.com/repos/laminas/laminas-filter/zipball/41cff2f850753f0bb3fc75c5ce011fcad6aa1731", + "reference": "41cff2f850753f0bb3fc75c5ce011fcad6aa1731", "shasum": "" }, "require": { - "laminas/laminas-stdlib": "^3.6.1", - "php": "^7.4 || ~8.0.0 || ~8.1.0" + "ext-mbstring": "*", + "laminas/laminas-servicemanager": "^3.14.0", + "laminas/laminas-stdlib": "^3.13.0", + "php": "~8.0.0 || ~8.1.0 || ~8.2.0" }, "conflict": { "laminas/laminas-validator": "<2.10.1", "zendframework/zend-filter": "*" }, "require-dev": { - "laminas/laminas-coding-standard": "^2.3.0", - "laminas/laminas-crypt": "^3.5.1", - "laminas/laminas-servicemanager": "^3.7.0", + "laminas/laminas-coding-standard": "~2.4.0", + "laminas/laminas-crypt": "^3.8", "laminas/laminas-uri": "^2.9.1", "pear/archive_tar": "^1.4.14", - "phpspec/prophecy-phpunit": "^2.0.1", - "phpunit/phpunit": "^9.5.10", - "psalm/plugin-phpunit": "^0.15.2", + "phpunit/phpunit": "^9.5.25", + "psalm/plugin-phpunit": "^0.17.0", "psr/http-factory": "^1.0.1", - "vimeo/psalm": "^4.13.1" + "vimeo/psalm": "^4.28" }, "suggest": { "laminas/laminas-crypt": "Laminas\\Crypt component, for encryption filters", "laminas/laminas-i18n": "Laminas\\I18n component for filters depending on i18n functionality", - "laminas/laminas-servicemanager": "Laminas\\ServiceManager component, for using the filter chain functionality", "laminas/laminas-uri": "Laminas\\Uri component, for the UriNormalize filter", "psr/http-factory-implementation": "psr/http-factory-implementation, for creating file upload instances when consuming PSR-7 in file upload filters" }, @@ -1539,20 +1541,20 @@ "type": "community_bridge" } ], - "time": "2022-02-22T23:09:15+00:00" + "time": "2022-10-11T10:04:14+00:00" }, { "name": "laminas/laminas-http", - "version": "2.15.1", + "version": "2.16.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-http.git", - "reference": "261f079c3dffcf6f123484db43c40e44c4bf1c79" + "reference": "7300482d3e570e81b6a6ecf6b28da1b12334bf63" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-http/zipball/261f079c3dffcf6f123484db43c40e44c4bf1c79", - "reference": "261f079c3dffcf6f123484db43c40e44c4bf1c79", + "url": "https://api.github.com/repos/laminas/laminas-http/zipball/7300482d3e570e81b6a6ecf6b28da1b12334bf63", + "reference": "7300482d3e570e81b6a6ecf6b28da1b12334bf63", "shasum": "" }, "require": { @@ -1604,26 +1606,27 @@ "type": "community_bridge" } ], - "time": "2021-12-03T10:17:11+00:00" + "time": "2022-08-17T17:22:15+00:00" }, { "name": "laminas/laminas-i18n", - "version": "2.15.0", + "version": "2.19.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-i18n.git", - "reference": "1654fcd6cd27c01a902b47fe71fa583ad227268c" + "reference": "ebabca3a6398fc872127bc69a51bda5afc720d67" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-i18n/zipball/1654fcd6cd27c01a902b47fe71fa583ad227268c", - "reference": "1654fcd6cd27c01a902b47fe71fa583ad227268c", + "url": "https://api.github.com/repos/laminas/laminas-i18n/zipball/ebabca3a6398fc872127bc69a51bda5afc720d67", + "reference": "ebabca3a6398fc872127bc69a51bda5afc720d67", "shasum": "" }, "require": { "ext-intl": "*", + "laminas/laminas-servicemanager": "^3.14.0", "laminas/laminas-stdlib": "^2.7 || ^3.0", - "php": "^7.4 || ~8.0.0 || ~8.1.0" + "php": "~8.0.0 || ~8.1.0 || ~8.2.0" }, "conflict": { "laminas/laminas-view": "<2.20.0", @@ -1631,20 +1634,18 @@ "zendframework/zend-i18n": "*" }, "require-dev": { - "laminas/laminas-cache": "^3.1.2", - "laminas/laminas-cache-storage-adapter-memory": "^2.0.0", - "laminas/laminas-cache-storage-deprecated-factory": "^1.0.0", - "laminas/laminas-coding-standard": "~2.3.0", - "laminas/laminas-config": "^3.4.0", - "laminas/laminas-eventmanager": "^3.4.0", - "laminas/laminas-filter": "^2.10.0", - "laminas/laminas-servicemanager": "^3.7.0", - "laminas/laminas-validator": "^2.14.0", - "laminas/laminas-view": "^2.20.0", - "phpspec/prophecy-phpunit": "^2.0", - "phpunit/phpunit": "^9.3", - "psalm/plugin-phpunit": "^0.16.1", - "vimeo/psalm": "^4.21" + "laminas/laminas-cache": "^3.6", + "laminas/laminas-cache-storage-adapter-memory": "^2.1", + "laminas/laminas-cache-storage-deprecated-factory": "^1.0.1", + "laminas/laminas-coding-standard": "~2.4.0", + "laminas/laminas-config": "^3.7", + "laminas/laminas-eventmanager": "^3.5.0", + "laminas/laminas-filter": "^2.21", + "laminas/laminas-validator": "^2.25", + "laminas/laminas-view": "^2.23", + "phpunit/phpunit": "^9.5.25", + "psalm/plugin-phpunit": "^0.17.0", + "vimeo/psalm": "^4.28" }, "suggest": { "laminas/laminas-cache": "You should install this package to cache the translations", @@ -1652,7 +1653,6 @@ "laminas/laminas-eventmanager": "You should install this package to use the events in the translator", "laminas/laminas-filter": "You should install this package to use the provided filters", "laminas/laminas-i18n-resources": "This package provides validator and captcha translations", - "laminas/laminas-servicemanager": "You should install this package to use the translator", "laminas/laminas-validator": "You should install this package to use the provided validators", "laminas/laminas-view": "You should install this package to use the provided view helpers" }, @@ -1692,7 +1692,7 @@ "type": "community_bridge" } ], - "time": "2022-04-01T10:47:19+00:00" + "time": "2022-10-10T15:48:56+00:00" }, { "name": "laminas/laminas-loader", @@ -1752,16 +1752,16 @@ }, { "name": "laminas/laminas-modulemanager", - "version": "2.11.0", + "version": "2.12.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-modulemanager.git", - "reference": "6acf5991d10b0b38a2edb08729ed48981b2a5dad" + "reference": "cd2dd3b3dc59e75a9f2117374222c0d84b25bf19" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-modulemanager/zipball/6acf5991d10b0b38a2edb08729ed48981b2a5dad", - "reference": "6acf5991d10b0b38a2edb08729ed48981b2a5dad", + "url": "https://api.github.com/repos/laminas/laminas-modulemanager/zipball/cd2dd3b3dc59e75a9f2117374222c0d84b25bf19", + "reference": "cd2dd3b3dc59e75a9f2117374222c0d84b25bf19", "shasum": "" }, "require": { @@ -1780,7 +1780,9 @@ "laminas/laminas-loader": "^2.8", "laminas/laminas-mvc": "^3.1.1", "laminas/laminas-servicemanager": "^3.7", - "phpunit/phpunit": "^9.5.5" + "phpunit/phpunit": "^9.5.5", + "psalm/plugin-phpunit": "^0.16.1", + "vimeo/psalm": "^4.10" }, "suggest": { "laminas/laminas-console": "Laminas\\Console component", @@ -1818,20 +1820,20 @@ "type": "community_bridge" } ], - "time": "2021-10-13T17:05:17+00:00" + "time": "2022-09-07T11:22:27+00:00" }, { "name": "laminas/laminas-mvc", - "version": "3.3.3", + "version": "3.3.5", "source": { "type": "git", "url": "https://github.com/laminas/laminas-mvc.git", - "reference": "7ff2bfbe64048aa83c6d1c7edcbab849123f0150" + "reference": "43fa8b0a02376cfe3209a91140bc97e94cd62d6e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-mvc/zipball/7ff2bfbe64048aa83c6d1c7edcbab849123f0150", - "reference": "7ff2bfbe64048aa83c6d1c7edcbab849123f0150", + "url": "https://api.github.com/repos/laminas/laminas-mvc/zipball/43fa8b0a02376cfe3209a91140bc97e94cd62d6e", + "reference": "43fa8b0a02376cfe3209a91140bc97e94cd62d6e", "shasum": "" }, "require": { @@ -1900,30 +1902,31 @@ "type": "community_bridge" } ], - "time": "2022-02-21T20:21:58+00:00" + "time": "2022-09-20T12:37:51+00:00" }, { "name": "laminas/laminas-mvc-i18n", - "version": "1.3.1", + "version": "1.4.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-mvc-i18n.git", - "reference": "3f6c81d839507dee8bbf74a09a9bfc65ecd3bb88" + "reference": "6dc949c045d7a2c27652a3bb891d46ef5e1814e4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-mvc-i18n/zipball/3f6c81d839507dee8bbf74a09a9bfc65ecd3bb88", - "reference": "3f6c81d839507dee8bbf74a09a9bfc65ecd3bb88", + "url": "https://api.github.com/repos/laminas/laminas-mvc-i18n/zipball/6dc949c045d7a2c27652a3bb891d46ef5e1814e4", + "reference": "6dc949c045d7a2c27652a3bb891d46ef5e1814e4", "shasum": "" }, "require": { "container-interop/container-interop": "^1.1", - "laminas/laminas-i18n": "^2.11", - "laminas/laminas-router": "^3.0", - "laminas/laminas-servicemanager": "^3.6", - "laminas/laminas-stdlib": "^3.3", - "laminas/laminas-validator": "^2.14", - "php": "^7.3 || ~8.0.0 || ~8.1.0" + "ext-intl": "*", + "laminas/laminas-i18n": "^2.13.0", + "laminas/laminas-router": "^3.5.0", + "laminas/laminas-servicemanager": "^3.15.1", + "laminas/laminas-stdlib": "^3.10.1", + "laminas/laminas-validator": "^2.19.0", + "php": "^7.4 || ~8.0.0 || ~8.1.0" }, "conflict": { "laminas/laminas-mvc": "<3.0.0", @@ -1931,11 +1934,11 @@ "zendframework/zend-mvc-i18n": "*" }, "require-dev": { - "laminas/laminas-coding-standard": "~1.0.0", + "laminas/laminas-coding-standard": "~2.3.0", "phpspec/prophecy-phpunit": "^2.0", "phpunit/phpunit": "^9.5", - "psalm/plugin-phpunit": "^0.15.1", - "vimeo/psalm": "^4.7" + "psalm/plugin-phpunit": "^0.17.0", + "vimeo/psalm": "^4.24.0" }, "suggest": { "laminas/laminas-cache": "To enable caching of translation strings" @@ -1977,20 +1980,20 @@ "type": "community_bridge" } ], - "time": "2022-02-25T14:13:55+00:00" + "time": "2022-07-21T16:59:34+00:00" }, { "name": "laminas/laminas-navigation", - "version": "2.13.2", + "version": "2.15.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-navigation.git", - "reference": "ca7c4df621bba21494b62722c46cd9326ca3e360" + "reference": "4818d772a3d51231c07e1ae3067e48ceef746b85" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-navigation/zipball/ca7c4df621bba21494b62722c46cd9326ca3e360", - "reference": "ca7c4df621bba21494b62722c46cd9326ca3e360", + "url": "https://api.github.com/repos/laminas/laminas-navigation/zipball/4818d772a3d51231c07e1ae3067e48ceef746b85", + "reference": "4818d772a3d51231c07e1ae3067e48ceef746b85", "shasum": "" }, "require": { @@ -2001,24 +2004,26 @@ "zendframework/zend-navigation": "*" }, "require-dev": { - "laminas/laminas-coding-standard": "^2.3.0", + "laminas/laminas-coding-standard": "~2.4.0", "laminas/laminas-config": "^3.7.0", - "laminas/laminas-http": "^2.15.1", - "laminas/laminas-i18n": "^2.13.0", - "laminas/laminas-mvc": "^3.3.0", - "laminas/laminas-permissions-acl": "^2.9.0", - "laminas/laminas-router": "^3.5.0", - "laminas/laminas-servicemanager": "^3.10.0", + "laminas/laminas-http": "^2.16.0", + "laminas/laminas-i18n": "^2.17.0", + "laminas/laminas-mvc": "^3.3.4", + "laminas/laminas-permissions-acl": "^2.10.0", + "laminas/laminas-router": "^3.9.0", + "laminas/laminas-servicemanager": "^3.16.0", "laminas/laminas-uri": "^2.9.1", - "laminas/laminas-view": "^2.14.2", + "laminas/laminas-view": "^2.22.1", "phpspec/prophecy-phpunit": "^2.0.1", - "phpunit/phpunit": "^9.5.10" + "phpunit/phpunit": "^9.5.24", + "psalm/plugin-phpunit": "^0.17.0", + "vimeo/psalm": "^4.27" }, "suggest": { "laminas/laminas-config": "^3.7, to provide page configuration (optional, as arrays and Traversables are also allowed)", "laminas/laminas-permissions-acl": "^2.9, to provide ACL-based access restrictions to pages", "laminas/laminas-router": "^3.5, to use router-based URI generation with Mvc pages", - "laminas/laminas-servicemanager": "^3.10, to use the navigation factories", + "laminas/laminas-servicemanager": "^3.16, to use the navigation factories", "laminas/laminas-view": "^2.14, to use the navigation view helpers" }, "type": "library", @@ -2057,25 +2062,25 @@ "type": "community_bridge" } ], - "time": "2022-02-16T21:41:34+00:00" + "time": "2022-09-13T11:14:03+00:00" }, { "name": "laminas/laminas-paginator", - "version": "2.12.2", + "version": "2.13.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-paginator.git", - "reference": "e2e5a17e2b6ca750e4a75b8f34763c63cc6bf8fa" + "reference": "2d6a9d21f5d67963347d497cd53873e3e693b0b5" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-paginator/zipball/e2e5a17e2b6ca750e4a75b8f34763c63cc6bf8fa", - "reference": "e2e5a17e2b6ca750e4a75b8f34763c63cc6bf8fa", + "url": "https://api.github.com/repos/laminas/laminas-paginator/zipball/2d6a9d21f5d67963347d497cd53873e3e693b0b5", + "reference": "2d6a9d21f5d67963347d497cd53873e3e693b0b5", "shasum": "" }, "require": { "ext-json": "*", - "laminas/laminas-stdlib": "^3.6.2", + "laminas/laminas-stdlib": "^3.10.1", "php": "^7.4 || ~8.0.0 || ~8.1.0" }, "conflict": { @@ -2087,11 +2092,11 @@ "laminas/laminas-coding-standard": "^2.3.0", "laminas/laminas-config": "^3.7.0", "laminas/laminas-filter": "^2.13.0", - "laminas/laminas-servicemanager": "^3.10.0", + "laminas/laminas-servicemanager": "^3.14.0", "laminas/laminas-view": "^2.15.0", - "phpunit/phpunit": "^9.5.10", + "phpunit/phpunit": "^9.5.21", "psalm/plugin-phpunit": "^0.16.1", - "vimeo/psalm": "^4.15.0" + "vimeo/psalm": "^4.24.0" }, "suggest": { "laminas/laminas-cache": "Laminas\\Cache component to support cache features", @@ -2136,35 +2141,35 @@ "type": "community_bridge" } ], - "time": "2022-01-11T18:09:02+00:00" + "time": "2022-07-12T11:56:05+00:00" }, { "name": "laminas/laminas-permissions-acl", - "version": "2.9.0", + "version": "2.10.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-permissions-acl.git", - "reference": "cd5689d8360c9a3f29bb62b32fc8ad45e0947e1e" + "reference": "e927ae0a3001655fea97eb240eeea9d10638e82f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-permissions-acl/zipball/cd5689d8360c9a3f29bb62b32fc8ad45e0947e1e", - "reference": "cd5689d8360c9a3f29bb62b32fc8ad45e0947e1e", + "url": "https://api.github.com/repos/laminas/laminas-permissions-acl/zipball/e927ae0a3001655fea97eb240eeea9d10638e82f", + "reference": "e927ae0a3001655fea97eb240eeea9d10638e82f", "shasum": "" }, "require": { - "php": "^7.3 || ~8.0.0 || ~8.1.0" + "php": "^7.4 || ~8.0.0 || ~8.1.0" }, "conflict": { "laminas/laminas-servicemanager": "<3.0", "zendframework/zend-permissions-acl": "*" }, "require-dev": { - "laminas/laminas-coding-standard": "~1.0.0", - "laminas/laminas-servicemanager": "^3.0.3", + "laminas/laminas-coding-standard": "~2.3.0", + "laminas/laminas-servicemanager": "^3.15.1", "phpunit/phpunit": "^9.5.0", - "psalm/plugin-phpunit": "^0.15.1", - "vimeo/psalm": "^4.7" + "psalm/plugin-phpunit": "^0.17.0", + "vimeo/psalm": "^4.24.0" }, "suggest": { "laminas/laminas-servicemanager": "To support Laminas\\Permissions\\Acl\\Assertion\\AssertionManager plugin manager usage" @@ -2199,41 +2204,40 @@ "type": "community_bridge" } ], - "time": "2021-12-03T08:59:59+00:00" + "time": "2022-07-21T09:23:39+00:00" }, { "name": "laminas/laminas-router", - "version": "3.5.0", + "version": "3.10.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-router.git", - "reference": "44759e71620030c93d99e40b394fe9fff8f0beda" + "reference": "84aa1047389270cc2b05e2fe85667efb592fbf5e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-router/zipball/44759e71620030c93d99e40b394fe9fff8f0beda", - "reference": "44759e71620030c93d99e40b394fe9fff8f0beda", + "url": "https://api.github.com/repos/laminas/laminas-router/zipball/84aa1047389270cc2b05e2fe85667efb592fbf5e", + "reference": "84aa1047389270cc2b05e2fe85667efb592fbf5e", "shasum": "" }, "require": { - "container-interop/container-interop": "^1.2", "laminas/laminas-http": "^2.15", - "laminas/laminas-servicemanager": "^3.7", - "laminas/laminas-stdlib": "^3.6", - "php": "^7.3 || ~8.0.0 || ~8.1.0" + "laminas/laminas-servicemanager": "^3.14.0", + "laminas/laminas-stdlib": "^3.10.1", + "php": "~8.0.0 || ~8.1.0 || ~8.2.0" }, "conflict": { "zendframework/zend-router": "*" }, "require-dev": { - "laminas/laminas-coding-standard": "~2.2.1", - "laminas/laminas-i18n": "^2.7.4", - "phpunit/phpunit": "^9.5.5", - "psalm/plugin-phpunit": "^0.15.1", - "vimeo/psalm": "^4.7" + "laminas/laminas-coding-standard": "~2.4.0", + "laminas/laminas-i18n": "^2.17", + "phpunit/phpunit": "^9.5.25", + "psalm/plugin-phpunit": "^0.17.0", + "vimeo/psalm": "^4.28" }, "suggest": { - "laminas/laminas-i18n": "^2.7.4, if defining translatable HTTP path segments" + "laminas/laminas-i18n": "^2.15.0 if defining translatable HTTP path segments" }, "type": "library", "extra": { @@ -2271,7 +2275,7 @@ "type": "community_bridge" } ], - "time": "2021-10-13T16:02:43+00:00" + "time": "2022-10-10T15:38:09+00:00" }, { "name": "laminas/laminas-uri", @@ -2333,42 +2337,40 @@ }, { "name": "laminas/laminas-validator", - "version": "2.20.1", + "version": "2.26.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-validator.git", - "reference": "90304417929a51e42999b115907a39f4b658c131" + "reference": "a995b21d18c63cd1f5d123d0d2cd31a1c2d828dc" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-validator/zipball/90304417929a51e42999b115907a39f4b658c131", - "reference": "90304417929a51e42999b115907a39f4b658c131", + "url": "https://api.github.com/repos/laminas/laminas-validator/zipball/a995b21d18c63cd1f5d123d0d2cd31a1c2d828dc", + "reference": "a995b21d18c63cd1f5d123d0d2cd31a1c2d828dc", "shasum": "" }, "require": { "laminas/laminas-servicemanager": "^3.12.0", - "laminas/laminas-stdlib": "^3.10", - "php": "^7.4 || ~8.0.0 || ~8.1.0" + "laminas/laminas-stdlib": "^3.13", + "php": "~8.0.0 || ~8.1.0 || ~8.2.0" }, "conflict": { "zendframework/zend-validator": "*" }, "require-dev": { - "laminas/laminas-cache": "^2.6.1", - "laminas/laminas-coding-standard": "~2.2.1", - "laminas/laminas-db": "^2.7", - "laminas/laminas-filter": "^2.14.0", - "laminas/laminas-http": "^2.14.2", - "laminas/laminas-i18n": "^2.15.0", - "laminas/laminas-session": "^2.12.1", + "laminas/laminas-coding-standard": "^2.4.0", + "laminas/laminas-db": "^2.15.0", + "laminas/laminas-filter": "^2.22", + "laminas/laminas-http": "^2.16.0", + "laminas/laminas-i18n": "^2.19", + "laminas/laminas-session": "^2.13.0", "laminas/laminas-uri": "^2.9.1", - "phpspec/prophecy-phpunit": "^2.0", - "phpunit/phpunit": "^9.5.5", - "psalm/plugin-phpunit": "^0.15.0", - "psr/http-client": "^1.0", - "psr/http-factory": "^1.0", - "psr/http-message": "^1.0", - "vimeo/psalm": "^4.23" + "phpunit/phpunit": "^9.5.25", + "psalm/plugin-phpunit": "^0.17.0", + "psr/http-client": "^1.0.1", + "psr/http-factory": "^1.0.1", + "psr/http-message": "^1.0.1", + "vimeo/psalm": "^4.28" }, "suggest": { "laminas/laminas-db": "Laminas\\Db component, required by the (No)RecordExists validator", @@ -2416,7 +2418,7 @@ "type": "community_bridge" } ], - "time": "2022-07-01T07:39:15+00:00" + "time": "2022-10-11T12:58:36+00:00" }, { "name": "myclabs/deep-copy", @@ -2530,16 +2532,16 @@ }, { "name": "nikic/php-parser", - "version": "v4.14.0", + "version": "v4.15.1", "source": { "type": "git", "url": "https://github.com/nikic/PHP-Parser.git", - "reference": "34bea19b6e03d8153165d8f30bba4c3be86184c1" + "reference": "0ef6c55a3f47f89d7a374e6f835197a0b5fcf900" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/34bea19b6e03d8153165d8f30bba4c3be86184c1", - "reference": "34bea19b6e03d8153165d8f30bba4c3be86184c1", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/0ef6c55a3f47f89d7a374e6f835197a0b5fcf900", + "reference": "0ef6c55a3f47f89d7a374e6f835197a0b5fcf900", "shasum": "" }, "require": { @@ -2580,9 +2582,9 @@ ], "support": { "issues": "https://github.com/nikic/PHP-Parser/issues", - "source": "https://github.com/nikic/PHP-Parser/tree/v4.14.0" + "source": "https://github.com/nikic/PHP-Parser/tree/v4.15.1" }, - "time": "2022-05-31T20:59:12+00:00" + "time": "2022-09-04T07:30:47+00:00" }, { "name": "openlss/lib-array2xml", @@ -2954,16 +2956,16 @@ }, { "name": "phpunit/php-code-coverage", - "version": "9.2.16", + "version": "9.2.17", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "2593003befdcc10db5e213f9f28814f5aa8ac073" + "reference": "aa94dc41e8661fe90c7316849907cba3007b10d8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/2593003befdcc10db5e213f9f28814f5aa8ac073", - "reference": "2593003befdcc10db5e213f9f28814f5aa8ac073", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/aa94dc41e8661fe90c7316849907cba3007b10d8", + "reference": "aa94dc41e8661fe90c7316849907cba3007b10d8", "shasum": "" }, "require": { @@ -3019,7 +3021,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", - "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.16" + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.17" }, "funding": [ { @@ -3027,7 +3029,7 @@ "type": "github" } ], - "time": "2022-08-20T05:26:47+00:00" + "time": "2022-08-30T12:24:04+00:00" }, { "name": "phpunit/php-file-iterator", @@ -3272,16 +3274,16 @@ }, { "name": "phpunit/phpunit", - "version": "9.5.23", + "version": "9.5.25", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "888556852e7e9bbeeedb9656afe46118765ade34" + "reference": "3e6f90ca7e3d02025b1d147bd8d4a89fd4ca8a1d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/888556852e7e9bbeeedb9656afe46118765ade34", - "reference": "888556852e7e9bbeeedb9656afe46118765ade34", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/3e6f90ca7e3d02025b1d147bd8d4a89fd4ca8a1d", + "reference": "3e6f90ca7e3d02025b1d147bd8d4a89fd4ca8a1d", "shasum": "" }, "require": { @@ -3303,14 +3305,14 @@ "phpunit/php-timer": "^5.0.2", "sebastian/cli-parser": "^1.0.1", "sebastian/code-unit": "^1.0.6", - "sebastian/comparator": "^4.0.5", + "sebastian/comparator": "^4.0.8", "sebastian/diff": "^4.0.3", "sebastian/environment": "^5.1.3", - "sebastian/exporter": "^4.0.3", + "sebastian/exporter": "^4.0.5", "sebastian/global-state": "^5.0.1", "sebastian/object-enumerator": "^4.0.3", "sebastian/resource-operations": "^3.0.3", - "sebastian/type": "^3.0", + "sebastian/type": "^3.2", "sebastian/version": "^3.0.2" }, "suggest": { @@ -3354,7 +3356,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", - "source": "https://github.com/sebastianbergmann/phpunit/tree/9.5.23" + "source": "https://github.com/sebastianbergmann/phpunit/tree/9.5.25" }, "funding": [ { @@ -3364,9 +3366,13 @@ { "url": "https://github.com/sebastianbergmann", "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/phpunit/phpunit", + "type": "tidelift" } ], - "time": "2022-08-22T14:01:36+00:00" + "time": "2022-09-25T03:44:45+00:00" }, { "name": "psalm/plugin-phpunit", @@ -3430,30 +3436,30 @@ }, { "name": "psr/log", - "version": "1.1.4", + "version": "3.0.0", "source": { "type": "git", "url": "https://github.com/php-fig/log.git", - "reference": "d49695b909c3b7628b6289db5479a1c204601f11" + "reference": "fe5ea303b0887d5caefd3d431c3e61ad47037001" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/log/zipball/d49695b909c3b7628b6289db5479a1c204601f11", - "reference": "d49695b909c3b7628b6289db5479a1c204601f11", + "url": "https://api.github.com/repos/php-fig/log/zipball/fe5ea303b0887d5caefd3d431c3e61ad47037001", + "reference": "fe5ea303b0887d5caefd3d431c3e61ad47037001", "shasum": "" }, "require": { - "php": ">=5.3.0" + "php": ">=8.0.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.1.x-dev" + "dev-master": "3.x-dev" } }, "autoload": { "psr-4": { - "Psr\\Log\\": "Psr/Log/" + "Psr\\Log\\": "src" } }, "notification-url": "https://packagist.org/downloads/", @@ -3474,9 +3480,9 @@ "psr-3" ], "support": { - "source": "https://github.com/php-fig/log/tree/1.1.4" + "source": "https://github.com/php-fig/log/tree/3.0.0" }, - "time": "2021-05-03T11:20:27+00:00" + "time": "2021-07-14T16:46:02+00:00" }, { "name": "sebastian/cli-parser", @@ -3647,16 +3653,16 @@ }, { "name": "sebastian/comparator", - "version": "4.0.6", + "version": "4.0.8", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/comparator.git", - "reference": "55f4261989e546dc112258c7a75935a81a7ce382" + "reference": "fa0f136dd2334583309d32b62544682ee972b51a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/55f4261989e546dc112258c7a75935a81a7ce382", - "reference": "55f4261989e546dc112258c7a75935a81a7ce382", + "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/fa0f136dd2334583309d32b62544682ee972b51a", + "reference": "fa0f136dd2334583309d32b62544682ee972b51a", "shasum": "" }, "require": { @@ -3709,7 +3715,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/comparator/issues", - "source": "https://github.com/sebastianbergmann/comparator/tree/4.0.6" + "source": "https://github.com/sebastianbergmann/comparator/tree/4.0.8" }, "funding": [ { @@ -3717,7 +3723,7 @@ "type": "github" } ], - "time": "2020-10-26T15:49:45+00:00" + "time": "2022-09-14T12:41:17+00:00" }, { "name": "sebastian/complexity", @@ -3907,16 +3913,16 @@ }, { "name": "sebastian/exporter", - "version": "4.0.4", + "version": "4.0.5", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/exporter.git", - "reference": "65e8b7db476c5dd267e65eea9cab77584d3cfff9" + "reference": "ac230ed27f0f98f597c8a2b6eb7ac563af5e5b9d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/65e8b7db476c5dd267e65eea9cab77584d3cfff9", - "reference": "65e8b7db476c5dd267e65eea9cab77584d3cfff9", + "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/ac230ed27f0f98f597c8a2b6eb7ac563af5e5b9d", + "reference": "ac230ed27f0f98f597c8a2b6eb7ac563af5e5b9d", "shasum": "" }, "require": { @@ -3972,7 +3978,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/exporter/issues", - "source": "https://github.com/sebastianbergmann/exporter/tree/4.0.4" + "source": "https://github.com/sebastianbergmann/exporter/tree/4.0.5" }, "funding": [ { @@ -3980,7 +3986,7 @@ "type": "github" } ], - "time": "2021-11-11T14:18:36+00:00" + "time": "2022-09-14T06:03:37+00:00" }, { "name": "sebastian/global-state", @@ -4335,16 +4341,16 @@ }, { "name": "sebastian/type", - "version": "3.0.0", + "version": "3.2.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/type.git", - "reference": "b233b84bc4465aff7b57cf1c4bc75c86d00d6dad" + "reference": "fb3fe09c5f0bae6bc27ef3ce933a1e0ed9464b6e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/b233b84bc4465aff7b57cf1c4bc75c86d00d6dad", - "reference": "b233b84bc4465aff7b57cf1c4bc75c86d00d6dad", + "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/fb3fe09c5f0bae6bc27ef3ce933a1e0ed9464b6e", + "reference": "fb3fe09c5f0bae6bc27ef3ce933a1e0ed9464b6e", "shasum": "" }, "require": { @@ -4356,7 +4362,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "3.0-dev" + "dev-master": "3.2-dev" } }, "autoload": { @@ -4379,7 +4385,7 @@ "homepage": "https://github.com/sebastianbergmann/type", "support": { "issues": "https://github.com/sebastianbergmann/type/issues", - "source": "https://github.com/sebastianbergmann/type/tree/3.0.0" + "source": "https://github.com/sebastianbergmann/type/tree/3.2.0" }, "funding": [ { @@ -4387,7 +4393,7 @@ "type": "github" } ], - "time": "2022-03-15T09:54:48+00:00" + "time": "2022-09-12T14:47:03+00:00" }, { "name": "sebastian/version", @@ -4561,46 +4567,43 @@ }, { "name": "symfony/console", - "version": "v5.4.11", + "version": "v6.1.5", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "535846c7ee6bc4dd027ca0d93220601456734b10" + "reference": "17524a64ebcfab68d237bbed247e9a9917747096" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/535846c7ee6bc4dd027ca0d93220601456734b10", - "reference": "535846c7ee6bc4dd027ca0d93220601456734b10", + "url": "https://api.github.com/repos/symfony/console/zipball/17524a64ebcfab68d237bbed247e9a9917747096", + "reference": "17524a64ebcfab68d237bbed247e9a9917747096", "shasum": "" }, "require": { - "php": ">=7.2.5", + "php": ">=8.1", "symfony/deprecation-contracts": "^2.1|^3", "symfony/polyfill-mbstring": "~1.0", - "symfony/polyfill-php73": "^1.9", - "symfony/polyfill-php80": "^1.16", "symfony/service-contracts": "^1.1|^2|^3", - "symfony/string": "^5.1|^6.0" + "symfony/string": "^5.4|^6.0" }, "conflict": { - "psr/log": ">=3", - "symfony/dependency-injection": "<4.4", - "symfony/dotenv": "<5.1", - "symfony/event-dispatcher": "<4.4", - "symfony/lock": "<4.4", - "symfony/process": "<4.4" + "symfony/dependency-injection": "<5.4", + "symfony/dotenv": "<5.4", + "symfony/event-dispatcher": "<5.4", + "symfony/lock": "<5.4", + "symfony/process": "<5.4" }, "provide": { - "psr/log-implementation": "1.0|2.0" + "psr/log-implementation": "1.0|2.0|3.0" }, "require-dev": { - "psr/log": "^1|^2", - "symfony/config": "^4.4|^5.0|^6.0", - "symfony/dependency-injection": "^4.4|^5.0|^6.0", - "symfony/event-dispatcher": "^4.4|^5.0|^6.0", - "symfony/lock": "^4.4|^5.0|^6.0", - "symfony/process": "^4.4|^5.0|^6.0", - "symfony/var-dumper": "^4.4|^5.0|^6.0" + "psr/log": "^1|^2|^3", + "symfony/config": "^5.4|^6.0", + "symfony/dependency-injection": "^5.4|^6.0", + "symfony/event-dispatcher": "^5.4|^6.0", + "symfony/lock": "^5.4|^6.0", + "symfony/process": "^5.4|^6.0", + "symfony/var-dumper": "^5.4|^6.0" }, "suggest": { "psr/log": "For using the console logger", @@ -4640,7 +4643,7 @@ "terminal" ], "support": { - "source": "https://github.com/symfony/console/tree/v5.4.11" + "source": "https://github.com/symfony/console/tree/v6.1.5" }, "funding": [ { @@ -4656,29 +4659,29 @@ "type": "tidelift" } ], - "time": "2022-07-22T10:42:43+00:00" + "time": "2022-09-03T14:24:42+00:00" }, { "name": "symfony/deprecation-contracts", - "version": "v2.5.2", + "version": "v3.1.1", "source": { "type": "git", "url": "https://github.com/symfony/deprecation-contracts.git", - "reference": "e8b495ea28c1d97b5e0c121748d6f9b53d075c66" + "reference": "07f1b9cc2ffee6aaafcf4b710fbc38ff736bd918" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/e8b495ea28c1d97b5e0c121748d6f9b53d075c66", - "reference": "e8b495ea28c1d97b5e0c121748d6f9b53d075c66", + "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/07f1b9cc2ffee6aaafcf4b710fbc38ff736bd918", + "reference": "07f1b9cc2ffee6aaafcf4b710fbc38ff736bd918", "shasum": "" }, "require": { - "php": ">=7.1" + "php": ">=8.1" }, "type": "library", "extra": { "branch-alias": { - "dev-main": "2.5-dev" + "dev-main": "3.1-dev" }, "thanks": { "name": "symfony/contracts", @@ -4707,7 +4710,7 @@ "description": "A generic function and convention to trigger deprecation notices", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/deprecation-contracts/tree/v2.5.2" + "source": "https://github.com/symfony/deprecation-contracts/tree/v3.1.1" }, "funding": [ { @@ -4723,7 +4726,7 @@ "type": "tidelift" } ], - "time": "2022-01-02T09:53:40+00:00" + "time": "2022-02-25T11:15:52+00:00" }, { "name": "symfony/polyfill-ctype", @@ -5055,85 +5058,6 @@ ], "time": "2022-05-24T11:49:31+00:00" }, - { - "name": "symfony/polyfill-php73", - "version": "v1.26.0", - "source": { - "type": "git", - "url": "https://github.com/symfony/polyfill-php73.git", - "reference": "e440d35fa0286f77fb45b79a03fedbeda9307e85" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-php73/zipball/e440d35fa0286f77fb45b79a03fedbeda9307e85", - "reference": "e440d35fa0286f77fb45b79a03fedbeda9307e85", - "shasum": "" - }, - "require": { - "php": ">=7.1" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-main": "1.26-dev" - }, - "thanks": { - "name": "symfony/polyfill", - "url": "https://github.com/symfony/polyfill" - } - }, - "autoload": { - "files": [ - "bootstrap.php" - ], - "psr-4": { - "Symfony\\Polyfill\\Php73\\": "" - }, - "classmap": [ - "Resources/stubs" - ] - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony polyfill backporting some PHP 7.3+ features to lower PHP versions", - "homepage": "https://symfony.com", - "keywords": [ - "compatibility", - "polyfill", - "portable", - "shim" - ], - "support": { - "source": "https://github.com/symfony/polyfill-php73/tree/v1.26.0" - }, - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], - "time": "2022-05-24T11:49:31+00:00" - }, { "name": "symfony/polyfill-php80", "version": "v1.26.0", @@ -5302,34 +5226,33 @@ }, { "name": "symfony/string", - "version": "v5.4.11", + "version": "v6.1.5", "source": { "type": "git", "url": "https://github.com/symfony/string.git", - "reference": "5eb661e49ad389e4ae2b6e4df8d783a8a6548322" + "reference": "17c08b068176996a1d7db8d00ffae3c248267016" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/string/zipball/5eb661e49ad389e4ae2b6e4df8d783a8a6548322", - "reference": "5eb661e49ad389e4ae2b6e4df8d783a8a6548322", + "url": "https://api.github.com/repos/symfony/string/zipball/17c08b068176996a1d7db8d00ffae3c248267016", + "reference": "17c08b068176996a1d7db8d00ffae3c248267016", "shasum": "" }, "require": { - "php": ">=7.2.5", + "php": ">=8.1", "symfony/polyfill-ctype": "~1.8", "symfony/polyfill-intl-grapheme": "~1.0", "symfony/polyfill-intl-normalizer": "~1.0", - "symfony/polyfill-mbstring": "~1.0", - "symfony/polyfill-php80": "~1.15" + "symfony/polyfill-mbstring": "~1.0" }, "conflict": { - "symfony/translation-contracts": ">=3.0" + "symfony/translation-contracts": "<2.0" }, "require-dev": { - "symfony/error-handler": "^4.4|^5.0|^6.0", - "symfony/http-client": "^4.4|^5.0|^6.0", - "symfony/translation-contracts": "^1.1|^2", - "symfony/var-exporter": "^4.4|^5.0|^6.0" + "symfony/error-handler": "^5.4|^6.0", + "symfony/http-client": "^5.4|^6.0", + "symfony/translation-contracts": "^2.0|^3.0", + "symfony/var-exporter": "^5.4|^6.0" }, "type": "library", "autoload": { @@ -5368,7 +5291,7 @@ "utf8" ], "support": { - "source": "https://github.com/symfony/string/tree/v5.4.11" + "source": "https://github.com/symfony/string/tree/v6.1.5" }, "funding": [ { @@ -5384,7 +5307,7 @@ "type": "tidelift" } ], - "time": "2022-07-24T16:15:25+00:00" + "time": "2022-09-02T08:05:20+00:00" }, { "name": "theseer/tokenizer", @@ -5438,16 +5361,16 @@ }, { "name": "vimeo/psalm", - "version": "4.26.0", + "version": "4.28.0", "source": { "type": "git", "url": "https://github.com/vimeo/psalm.git", - "reference": "6998fabb2bf528b65777bf9941920888d23c03ac" + "reference": "52e96bea381e6cb07a672aefec791a5817694a26" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/vimeo/psalm/zipball/6998fabb2bf528b65777bf9941920888d23c03ac", - "reference": "6998fabb2bf528b65777bf9941920888d23c03ac", + "url": "https://api.github.com/repos/vimeo/psalm/zipball/52e96bea381e6cb07a672aefec791a5817694a26", + "reference": "52e96bea381e6cb07a672aefec791a5817694a26", "shasum": "" }, "require": { @@ -5486,6 +5409,7 @@ "phpdocumentor/reflection-docblock": "^5", "phpmyadmin/sql-parser": "5.1.0||dev-master", "phpspec/prophecy": ">=1.9.0", + "phpstan/phpdoc-parser": "1.2.* || 1.6.4", "phpunit/phpunit": "^9.0", "psalm/plugin-phpunit": "^0.16", "slevomat/coding-standard": "^7.0", @@ -5539,9 +5463,9 @@ ], "support": { "issues": "https://github.com/vimeo/psalm/issues", - "source": "https://github.com/vimeo/psalm/tree/4.26.0" + "source": "https://github.com/vimeo/psalm/tree/4.28.0" }, - "time": "2022-07-31T13:10:26+00:00" + "time": "2022-10-07T16:13:24+00:00" }, { "name": "webimpress/coding-standard", @@ -5773,14 +5697,14 @@ "prefer-stable": false, "prefer-lowest": false, "platform": { - "php": "^7.4 || ~8.0.0 || ~8.1.0", + "php": "~8.0.0 || ~8.1.0 || ~8.2.0", "ext-dom": "*", "ext-filter": "*", "ext-json": "*" }, "platform-dev": [], "platform-overrides": { - "php": "7.4" + "php": "8.0.99" }, "plugin-api-version": "2.3.0" } From ca33d906e1ef6b5cb541ddb80e35b9c8d5e69bb4 Mon Sep 17 00:00:00 2001 From: George Steel Date: Tue, 11 Oct 2022 18:05:41 +0100 Subject: [PATCH 27/58] Regenerate baseline post merge-up Signed-off-by: George Steel --- psalm-baseline.xml | 82 +++++++++------------------------------------- 1 file changed, 15 insertions(+), 67 deletions(-) diff --git a/psalm-baseline.xml b/psalm-baseline.xml index 2022e405e..1265100e2 100644 --- a/psalm-baseline.xml +++ b/psalm-baseline.xml @@ -1,5 +1,5 @@ - + $templatePath @@ -52,17 +52,6 @@ plugin - - - null === $this->basePath - - - $basePath - - - $file - - Cycle @@ -1370,38 +1359,27 @@ + + $_SERVER['SERVER_PORT'] + $port + string string - - $_SERVER['HTTP_HOST'] - $_SERVER['HTTP_HOST'] - $_SERVER['HTTP_X_FORWARDED_PROTO'] - $_SERVER['SERVER_PORT'] - $_SERVER['SSL_HTTPS'] - $host - $host - $host - $name - $port - - - $host - $name - $path - $port - - - $path - $this->host $this->scheme + + $_SERVER['REQUEST_URI'] + (bool) $useProxy + + $_SERVER['HTTPS'] === true + @@ -2070,10 +2048,6 @@ iterable - - __invoke - plugin - $attributeEscaper($link['href']) $attributeEscaper($link['href']) @@ -2113,12 +2087,6 @@ getValue setIndent - - $this->view - - - $this->view - @@ -2386,9 +2354,6 @@ - - (new RouterConfigProvider())->getDependencyConfig() - $app @@ -2420,7 +2385,7 @@ - + $active $active $active @@ -2431,9 +2396,6 @@ $active $found $found - $found - $found - $found $active @@ -2548,9 +2510,6 @@ $_helper - - $found - getHref getLabel @@ -2630,11 +2589,6 @@ setBasePath - - $this->oldServer - $this->oldServer - $this->oldServer - $_helper @@ -2913,9 +2867,6 @@ $serviceConfig $test - - (new RouterConfigProvider())->getDependencyConfig() - $router $serviceConfig @@ -2973,15 +2924,15 @@ - - $vars - new stdClass() new stdClass() + + $vars + $variables $variables @@ -2989,9 +2940,6 @@ - - $content - $content From 6222ce3db8377ce3694a409429c17d7dcc682a37 Mon Sep 17 00:00:00 2001 From: George Steel Date: Mon, 7 Nov 2022 08:46:49 +0000 Subject: [PATCH 28/58] Refresh lock file Signed-off-by: George Steel --- composer.lock | 347 +++++--------------------------------------------- 1 file changed, 33 insertions(+), 314 deletions(-) diff --git a/composer.lock b/composer.lock index 022ddb57e..7ee3b0f15 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "21dfca7852c0f51f402cb1555c7d4515", + "content-hash": "c7b1eada80989d6e0c804c2935314636", "packages": [ { "name": "laminas/laminas-escaper", @@ -1385,72 +1385,6 @@ ], "time": "2022-10-16T14:21:22+00:00" }, - { - "name": "laminas/laminas-console", - "version": "2.8.0", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-console.git", - "reference": "478a6ceac3e31fb38d6314088abda8b239ee23a5" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-console/zipball/478a6ceac3e31fb38d6314088abda8b239ee23a5", - "reference": "478a6ceac3e31fb38d6314088abda8b239ee23a5", - "shasum": "" - }, - "require": { - "laminas/laminas-stdlib": "^3.2.1", - "laminas/laminas-zendframework-bridge": "^1.0", - "php": "^5.6 || ^7.0" - }, - "replace": { - "zendframework/zend-console": "self.version" - }, - "require-dev": { - "laminas/laminas-coding-standard": "~1.0.0", - "laminas/laminas-filter": "^2.7.2", - "laminas/laminas-json": "^2.6 || ^3.0", - "laminas/laminas-validator": "^2.10.1", - "phpunit/phpunit": "^5.7.23 || ^6.4.3" - }, - "suggest": { - "laminas/laminas-filter": "To support DefaultRouteMatcher usage", - "laminas/laminas-validator": "To support DefaultRouteMatcher usage" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.8.x-dev", - "dev-develop": "2.9.x-dev" - } - }, - "autoload": { - "psr-4": { - "Laminas\\Console\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Build console applications using getopt syntax or routing, complete with prompts", - "homepage": "https://laminas.dev", - "keywords": [ - "console", - "laminas" - ], - "support": { - "chat": "https://laminas.dev/chat", - "docs": "https://docs.laminas.dev/laminas-console/", - "forum": "https://discourse.laminas.dev", - "issues": "https://github.com/laminas/laminas-console/issues", - "rss": "https://github.com/laminas/laminas-console/releases.atom", - "source": "https://github.com/laminas/laminas-console" - }, - "abandoned": "laminas/laminas-cli", - "time": "2019-12-31T16:31:45+00:00" - }, { "name": "laminas/laminas-feed", "version": "2.19.0", @@ -1533,16 +1467,16 @@ }, { "name": "laminas/laminas-filter", - "version": "2.25.0", + "version": "2.26.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-filter.git", - "reference": "49ead1dc8043ee2036f296d0ce1e132d6d0ccacf" + "reference": "7248f26ed9ef0979ccd6ebe3dd4b38ef229bb71b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-filter/zipball/49ead1dc8043ee2036f296d0ce1e132d6d0ccacf", - "reference": "49ead1dc8043ee2036f296d0ce1e132d6d0ccacf", + "url": "https://api.github.com/repos/laminas/laminas-filter/zipball/7248f26ed9ef0979ccd6ebe3dd4b38ef229bb71b", + "reference": "7248f26ed9ef0979ccd6ebe3dd4b38ef229bb71b", "shasum": "" }, "require": { @@ -1557,13 +1491,13 @@ }, "require-dev": { "laminas/laminas-coding-standard": "~2.4.0", - "laminas/laminas-crypt": "^3.8", - "laminas/laminas-uri": "^2.9.1", + "laminas/laminas-crypt": "^3.9", + "laminas/laminas-uri": "^2.10", "pear/archive_tar": "^1.4.14", - "phpunit/phpunit": "^9.5.25", - "psalm/plugin-phpunit": "^0.18.0", + "phpunit/phpunit": "^9.5.26", + "psalm/plugin-phpunit": "^0.18.3", "psr/http-factory": "^1.0.1", - "vimeo/psalm": "^4.28" + "vimeo/psalm": "^4.30" }, "suggest": { "laminas/laminas-crypt": "Laminas\\Crypt component, for encryption filters", @@ -1607,7 +1541,7 @@ "type": "community_bridge" } ], - "time": "2022-11-06T15:02:35+00:00" + "time": "2022-11-07T08:12:46+00:00" }, { "name": "laminas/laminas-http", @@ -2049,75 +1983,6 @@ ], "time": "2022-10-24T07:54:49+00:00" }, - { - "name": "laminas/laminas-mvc-plugin-flashmessenger", - "version": "1.9.0", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-mvc-plugin-flashmessenger.git", - "reference": "dc73bb6b56a0d74f9fdc0d24ec55a5f8c87c4cfa" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-mvc-plugin-flashmessenger/zipball/dc73bb6b56a0d74f9fdc0d24ec55a5f8c87c4cfa", - "reference": "dc73bb6b56a0d74f9fdc0d24ec55a5f8c87c4cfa", - "shasum": "" - }, - "require": { - "laminas/laminas-mvc": "^3.3", - "laminas/laminas-session": "^2.12.0", - "laminas/laminas-stdlib": "^3.6.4", - "laminas/laminas-view": "^2.13.1", - "php": "~8.0.0 || ~8.1.0 || ~8.2.0" - }, - "conflict": { - "laminas/laminas-mvc": "<3.0.0", - "zendframework/zend-mvc-plugin-flashmessenger": "*" - }, - "require-dev": { - "laminas/laminas-coding-standard": "~2.4.0", - "laminas/laminas-i18n": "^2.19.0", - "phpunit/phpunit": "^9.5.25", - "psalm/plugin-phpunit": "^0.17.0", - "vimeo/psalm": "^4.29.0" - }, - "type": "library", - "extra": { - "laminas": { - "component": "Laminas\\Mvc\\Plugin\\FlashMessenger" - } - }, - "autoload": { - "psr-4": { - "Laminas\\Mvc\\Plugin\\FlashMessenger\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Plugin for creating and exposing flash messages via laminas-mvc controllers", - "homepage": "https://laminas.dev", - "keywords": [ - "laminas", - "mvc" - ], - "support": { - "chat": "https://laminas.dev/chat", - "docs": "https://docs.laminas.dev/laminas-mvc-plugin-flashmessenger/", - "forum": "https://discourse.laminas.dev", - "issues": "https://github.com/laminas/laminas-mvc-plugin-flashmessenger/issues", - "rss": "https://github.com/laminas/laminas-mvc-plugin-flashmessenger/releases.atom", - "source": "https://github.com/laminas/laminas-mvc-plugin-flashmessenger" - }, - "funding": [ - { - "url": "https://funding.communitybridge.org/projects/laminas-project", - "type": "community_bridge" - } - ], - "time": "2022-10-22T12:47:30+00:00" - }, { "name": "laminas/laminas-navigation", "version": "2.16.0", @@ -2412,89 +2277,6 @@ ], "time": "2022-10-10T15:38:09+00:00" }, - { - "name": "laminas/laminas-session", - "version": "2.13.0", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-session.git", - "reference": "9f8a6077dd22b3b253583b1be84ddd5bf6fa1ef4" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-session/zipball/9f8a6077dd22b3b253583b1be84ddd5bf6fa1ef4", - "reference": "9f8a6077dd22b3b253583b1be84ddd5bf6fa1ef4", - "shasum": "" - }, - "require": { - "laminas/laminas-eventmanager": "^3.5", - "laminas/laminas-servicemanager": "^3.15.1", - "laminas/laminas-stdlib": "^3.10.1", - "php": "^7.4 || ~8.0.0 || ~8.1.0" - }, - "conflict": { - "zendframework/zend-session": "*" - }, - "require-dev": { - "laminas/laminas-cache": "^3.1.3", - "laminas/laminas-cache-storage-adapter-memory": "^2.0.0", - "laminas/laminas-coding-standard": "~2.3.0", - "laminas/laminas-db": "^2.13.4", - "laminas/laminas-http": "^2.15", - "laminas/laminas-validator": "^2.15", - "mongodb/mongodb": "~1.12.0", - "php-mock/php-mock-phpunit": "^1.1.2 || ^2.0", - "phpspec/prophecy-phpunit": "^2.0", - "phpunit/phpunit": "^9.5.9", - "psalm/plugin-phpunit": "^0.17.0", - "vimeo/psalm": "^4.24.0" - }, - "suggest": { - "laminas/laminas-cache": "Laminas\\Cache component", - "laminas/laminas-db": "Laminas\\Db component", - "laminas/laminas-http": "Laminas\\Http component", - "laminas/laminas-servicemanager": "Laminas\\ServiceManager component", - "laminas/laminas-validator": "Laminas\\Validator component", - "mongodb/mongodb": "If you want to use the MongoDB session save handler" - }, - "type": "library", - "extra": { - "laminas": { - "component": "Laminas\\Session", - "config-provider": "Laminas\\Session\\ConfigProvider" - } - }, - "autoload": { - "psr-4": { - "Laminas\\Session\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Object-oriented interface to PHP sessions and storage", - "homepage": "https://laminas.dev", - "keywords": [ - "laminas", - "session" - ], - "support": { - "chat": "https://laminas.dev/chat", - "docs": "https://docs.laminas.dev/laminas-session/", - "forum": "https://discourse.laminas.dev", - "issues": "https://github.com/laminas/laminas-session/issues", - "rss": "https://github.com/laminas/laminas-session/releases.atom", - "source": "https://github.com/laminas/laminas-session" - }, - "funding": [ - { - "url": "https://funding.communitybridge.org/projects/laminas-project", - "type": "community_bridge" - } - ], - "time": "2022-07-22T10:26:33+00:00" - }, { "name": "laminas/laminas-uri", "version": "2.10.0", @@ -2638,68 +2420,6 @@ ], "time": "2022-10-11T12:58:36+00:00" }, - { - "name": "laminas/laminas-zendframework-bridge", - "version": "1.6.1", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-zendframework-bridge.git", - "reference": "e112dd2c099f4f6142c16fc65fda89a638e06885" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-zendframework-bridge/zipball/e112dd2c099f4f6142c16fc65fda89a638e06885", - "reference": "e112dd2c099f4f6142c16fc65fda89a638e06885", - "shasum": "" - }, - "require": { - "php": ">=7.4, <8.2" - }, - "require-dev": { - "phpunit/phpunit": "^9.5.14", - "psalm/plugin-phpunit": "^0.15.2", - "squizlabs/php_codesniffer": "^3.6.2", - "vimeo/psalm": "^4.21.0" - }, - "type": "library", - "extra": { - "laminas": { - "module": "Laminas\\ZendFrameworkBridge" - } - }, - "autoload": { - "files": [ - "src/autoload.php" - ], - "psr-4": { - "Laminas\\ZendFrameworkBridge\\": "src//" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Alias legacy ZF class names to Laminas Project equivalents.", - "keywords": [ - "ZendFramework", - "autoloading", - "laminas", - "zf" - ], - "support": { - "forum": "https://discourse.laminas.dev/", - "issues": "https://github.com/laminas/laminas-zendframework-bridge/issues", - "rss": "https://github.com/laminas/laminas-zendframework-bridge/releases.atom", - "source": "https://github.com/laminas/laminas-zendframework-bridge" - }, - "funding": [ - { - "url": "https://funding.communitybridge.org/projects/laminas-project", - "type": "community_bridge" - } - ], - "time": "2022-07-29T13:28:29+00:00" - }, { "name": "myclabs/deep-copy", "version": "1.11.0", @@ -4852,21 +4572,20 @@ }, { "name": "symfony/console", - "version": "v6.1.7", + "version": "v6.0.15", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "a1282bd0c096e0bdb8800b104177e2ce404d8815" + "reference": "b0b910724a0a0326b4481e4f8a30abb2dd442efb" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/a1282bd0c096e0bdb8800b104177e2ce404d8815", - "reference": "a1282bd0c096e0bdb8800b104177e2ce404d8815", + "url": "https://api.github.com/repos/symfony/console/zipball/b0b910724a0a0326b4481e4f8a30abb2dd442efb", + "reference": "b0b910724a0a0326b4481e4f8a30abb2dd442efb", "shasum": "" }, "require": { - "php": ">=8.1", - "symfony/deprecation-contracts": "^2.1|^3", + "php": ">=8.0.2", "symfony/polyfill-mbstring": "~1.0", "symfony/service-contracts": "^1.1|^2|^3", "symfony/string": "^5.4|^6.0" @@ -4928,7 +4647,7 @@ "terminal" ], "support": { - "source": "https://github.com/symfony/console/tree/v6.1.7" + "source": "https://github.com/symfony/console/tree/v6.0.15" }, "funding": [ { @@ -4944,29 +4663,29 @@ "type": "tidelift" } ], - "time": "2022-10-26T21:42:49+00:00" + "time": "2022-10-26T21:42:20+00:00" }, { "name": "symfony/deprecation-contracts", - "version": "v3.1.1", + "version": "v3.0.2", "source": { "type": "git", "url": "https://github.com/symfony/deprecation-contracts.git", - "reference": "07f1b9cc2ffee6aaafcf4b710fbc38ff736bd918" + "reference": "26954b3d62a6c5fd0ea8a2a00c0353a14978d05c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/07f1b9cc2ffee6aaafcf4b710fbc38ff736bd918", - "reference": "07f1b9cc2ffee6aaafcf4b710fbc38ff736bd918", + "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/26954b3d62a6c5fd0ea8a2a00c0353a14978d05c", + "reference": "26954b3d62a6c5fd0ea8a2a00c0353a14978d05c", "shasum": "" }, "require": { - "php": ">=8.1" + "php": ">=8.0.2" }, "type": "library", "extra": { "branch-alias": { - "dev-main": "3.1-dev" + "dev-main": "3.0-dev" }, "thanks": { "name": "symfony/contracts", @@ -4995,7 +4714,7 @@ "description": "A generic function and convention to trigger deprecation notices", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/deprecation-contracts/tree/v3.1.1" + "source": "https://github.com/symfony/deprecation-contracts/tree/v3.0.2" }, "funding": [ { @@ -5011,7 +4730,7 @@ "type": "tidelift" } ], - "time": "2022-02-25T11:15:52+00:00" + "time": "2022-01-02T09:55:41+00:00" }, { "name": "symfony/polyfill-ctype", @@ -5511,20 +5230,20 @@ }, { "name": "symfony/string", - "version": "v6.1.7", + "version": "v6.0.15", "source": { "type": "git", "url": "https://github.com/symfony/string.git", - "reference": "823f143370880efcbdfa2dbca946b3358c4707e5" + "reference": "51ac0fa0ccf132a00519b87c97e8f775fa14e771" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/string/zipball/823f143370880efcbdfa2dbca946b3358c4707e5", - "reference": "823f143370880efcbdfa2dbca946b3358c4707e5", + "url": "https://api.github.com/repos/symfony/string/zipball/51ac0fa0ccf132a00519b87c97e8f775fa14e771", + "reference": "51ac0fa0ccf132a00519b87c97e8f775fa14e771", "shasum": "" }, "require": { - "php": ">=8.1", + "php": ">=8.0.2", "symfony/polyfill-ctype": "~1.8", "symfony/polyfill-intl-grapheme": "~1.0", "symfony/polyfill-intl-normalizer": "~1.0", @@ -5576,7 +5295,7 @@ "utf8" ], "support": { - "source": "https://github.com/symfony/string/tree/v6.1.7" + "source": "https://github.com/symfony/string/tree/v6.0.15" }, "funding": [ { @@ -5592,7 +5311,7 @@ "type": "tidelift" } ], - "time": "2022-10-10T09:34:31+00:00" + "time": "2022-10-10T09:34:08+00:00" }, { "name": "theseer/tokenizer", From a6b172b9cc4ed403dd1186c60b3dbcd890da8538 Mon Sep 17 00:00:00 2001 From: George Steel Date: Mon, 7 Nov 2022 08:50:08 +0000 Subject: [PATCH 29/58] Correct mvc constraint post merge-up Signed-off-by: George Steel --- composer.json | 2 +- composer.lock | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/composer.json b/composer.json index 1b6a3b48e..c7219e172 100644 --- a/composer.json +++ b/composer.json @@ -45,7 +45,7 @@ "laminas/laminas-http": "^2.17", "laminas/laminas-i18n": "^2.19", "laminas/laminas-modulemanager": "^2.14", - "laminas/laminas-mvc": "^3.3.5", + "laminas/laminas-mvc": "^3.5", "laminas/laminas-mvc-i18n": "^1.6", "laminas/laminas-navigation": "^2.16", "laminas/laminas-paginator": "^2.15", diff --git a/composer.lock b/composer.lock index 7ee3b0f15..9ecb6d74d 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "c7b1eada80989d6e0c804c2935314636", + "content-hash": "7903620a91678a58f2d7767a8a87bf10", "packages": [ { "name": "laminas/laminas-escaper", From 5a3bdc205499cdde0cb0a31c86e17317d473de94 Mon Sep 17 00:00:00 2001 From: George Steel Date: Sun, 15 Jan 2023 09:54:32 +0000 Subject: [PATCH 30/58] Update lock and baseline post merge-up Signed-off-by: George Steel --- composer.lock | 152 +---------------------- psalm-baseline.xml | 304 +++------------------------------------------ 2 files changed, 15 insertions(+), 441 deletions(-) diff --git a/composer.lock b/composer.lock index 45b5df741..28e467b5d 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "dd2ee7c1a95d1b511f67a0eda4ea68ce", + "content-hash": "1ba005afd2649475e4f5729e6c7d7e87", "packages": [ { "name": "laminas/laminas-escaper", @@ -2044,75 +2044,6 @@ ], "time": "2022-12-02T15:45:50+00:00" }, - { - "name": "laminas/laminas-mvc-plugin-flashmessenger", - "version": "1.9.0", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-mvc-plugin-flashmessenger.git", - "reference": "dc73bb6b56a0d74f9fdc0d24ec55a5f8c87c4cfa" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-mvc-plugin-flashmessenger/zipball/dc73bb6b56a0d74f9fdc0d24ec55a5f8c87c4cfa", - "reference": "dc73bb6b56a0d74f9fdc0d24ec55a5f8c87c4cfa", - "shasum": "" - }, - "require": { - "laminas/laminas-mvc": "^3.3", - "laminas/laminas-session": "^2.12.0", - "laminas/laminas-stdlib": "^3.6.4", - "laminas/laminas-view": "^2.13.1", - "php": "~8.0.0 || ~8.1.0 || ~8.2.0" - }, - "conflict": { - "laminas/laminas-mvc": "<3.0.0", - "zendframework/zend-mvc-plugin-flashmessenger": "*" - }, - "require-dev": { - "laminas/laminas-coding-standard": "~2.4.0", - "laminas/laminas-i18n": "^2.19.0", - "phpunit/phpunit": "^9.5.25", - "psalm/plugin-phpunit": "^0.17.0", - "vimeo/psalm": "^4.29.0" - }, - "type": "library", - "extra": { - "laminas": { - "component": "Laminas\\Mvc\\Plugin\\FlashMessenger" - } - }, - "autoload": { - "psr-4": { - "Laminas\\Mvc\\Plugin\\FlashMessenger\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Plugin for creating and exposing flash messages via laminas-mvc controllers", - "homepage": "https://laminas.dev", - "keywords": [ - "laminas", - "mvc" - ], - "support": { - "chat": "https://laminas.dev/chat", - "docs": "https://docs.laminas.dev/laminas-mvc-plugin-flashmessenger/", - "forum": "https://discourse.laminas.dev", - "issues": "https://github.com/laminas/laminas-mvc-plugin-flashmessenger/issues", - "rss": "https://github.com/laminas/laminas-mvc-plugin-flashmessenger/releases.atom", - "source": "https://github.com/laminas/laminas-mvc-plugin-flashmessenger" - }, - "funding": [ - { - "url": "https://funding.communitybridge.org/projects/laminas-project", - "type": "community_bridge" - } - ], - "time": "2022-10-22T12:47:30+00:00" - }, { "name": "laminas/laminas-navigation", "version": "2.18.1", @@ -2407,87 +2338,6 @@ ], "time": "2022-12-29T14:47:23+00:00" }, - { - "name": "laminas/laminas-session", - "version": "2.16.0", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-session.git", - "reference": "9c845a0361625d5775cad6f043716196201ad41f" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-session/zipball/9c845a0361625d5775cad6f043716196201ad41f", - "reference": "9c845a0361625d5775cad6f043716196201ad41f", - "shasum": "" - }, - "require": { - "laminas/laminas-eventmanager": "^3.5", - "laminas/laminas-servicemanager": "^3.15.1", - "laminas/laminas-stdlib": "^3.10.1", - "php": "~8.0.0 || ~8.1.0 || ~8.2.0" - }, - "conflict": { - "zendframework/zend-session": "*" - }, - "require-dev": { - "laminas/laminas-cache": "^3.8", - "laminas/laminas-cache-storage-adapter-memory": "^2.2", - "laminas/laminas-coding-standard": "~2.4.0", - "laminas/laminas-db": "^2.15", - "laminas/laminas-http": "^2.17.1", - "laminas/laminas-validator": "^2.28", - "mongodb/mongodb": "~1.13.0", - "phpunit/phpunit": "^9.5.26", - "psalm/plugin-phpunit": "^0.18.0", - "vimeo/psalm": "^5.0" - }, - "suggest": { - "laminas/laminas-cache": "Laminas\\Cache component", - "laminas/laminas-db": "Laminas\\Db component", - "laminas/laminas-http": "Laminas\\Http component", - "laminas/laminas-servicemanager": "Laminas\\ServiceManager component", - "laminas/laminas-validator": "Laminas\\Validator component", - "mongodb/mongodb": "If you want to use the MongoDB session save handler" - }, - "type": "library", - "extra": { - "laminas": { - "component": "Laminas\\Session", - "config-provider": "Laminas\\Session\\ConfigProvider" - } - }, - "autoload": { - "psr-4": { - "Laminas\\Session\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Object-oriented interface to PHP sessions and storage", - "homepage": "https://laminas.dev", - "keywords": [ - "laminas", - "session" - ], - "support": { - "chat": "https://laminas.dev/chat", - "docs": "https://docs.laminas.dev/laminas-session/", - "forum": "https://discourse.laminas.dev", - "issues": "https://github.com/laminas/laminas-session/issues", - "rss": "https://github.com/laminas/laminas-session/releases.atom", - "source": "https://github.com/laminas/laminas-session" - }, - "funding": [ - { - "url": "https://funding.communitybridge.org/projects/laminas-project", - "type": "community_bridge" - } - ], - "time": "2022-12-04T11:15:36+00:00" - }, { "name": "laminas/laminas-uri", "version": "2.10.0", diff --git a/psalm-baseline.xml b/psalm-baseline.xml index 110c63553..bfae02849 100644 --- a/psalm-baseline.xml +++ b/psalm-baseline.xml @@ -19,9 +19,7 @@ - - $closingBracket - $closingBracket + $closingBracket $closingBracket $closingBracket @@ -140,46 +138,6 @@ $value[$k] - - - null === $this->pluginFlashMessenger - - - $item - - - $escapeHtmlHelper - $pluginFlashMessenger - - - $item - $messagesToPrint - - - $classes - $classes - - - $messagesToPrint[] - $messagesToPrint[] - - - $classes - $classes - $messagesToPrint[] - $messagesToPrint[] - $this->escapeHtmlHelper - - - (bool) $autoEscape - (string) $messageCloseString - (string) $messageOpenFormat - (string) $messageSeparatorString - - - $this->escapeHtmlHelper - - $flag === null @@ -579,26 +537,6 @@ translate - - - $htmlObject - - - $htmlObject($data, self::TYPE, $attribs, $params, $content) - - - string - - - $htmlObject($data, self::TYPE, $attribs, $params, $content) - - - plugin - - - plugin - - is_array($content) @@ -631,26 +569,6 @@ plugin - - - $htmlObject - - - $htmlObject($data, self::TYPE, $attribs, $params, $content) - - - string - - - $htmlObject($data, self::TYPE, $attribs, $params, $content) - - - plugin - - - plugin - - $value @@ -681,17 +599,6 @@ InlineScript - - - $response - - - null - - - $this->response instanceof Response - - plugin @@ -1268,12 +1175,11 @@ $this->items - + (string) $key (string) $key (string) $key (string) $key - (string) $name @@ -1371,9 +1277,6 @@ - - null === static::$instance - new $this->containerClass($value) @@ -1396,9 +1299,6 @@ (string) $key (string) $key - - new static() - @@ -1478,11 +1378,6 @@ $_SERVER['HTTPS'] === true - - - $cName - - $config['view_helper_config']['doctype'] @@ -1495,50 +1390,7 @@ $config - - - FlashMessenger - FlashMessenger - new FlashMessenger() - - - FlashMessengerFactory - - - $configHelper['message_close_string'] - $configHelper['message_open_format'] - $configHelper['message_separator_string'] - $flashMessenger - - - $configHelper['message_close_string'] - $configHelper['message_open_format'] - $configHelper['message_separator_string'] - $config['view_helper_config'] - $config['view_helper_config']['flashmessenger'] - - - $config - $configHelper - $controllerPluginManager - $flashMessenger - - - get - - - $container - - - $requestedName - - - - $this - $this - $this - (bool) $enabled @@ -1619,17 +1471,6 @@ clearVariables - - - int - - - $this->options['errorLevel'] - - - $captureTo - - $this->type @@ -1656,6 +1497,9 @@ $captureTo + + (int) $e->getCode() + @@ -1716,29 +1560,6 @@ is_object($variables) - - - $values - - - $child - - - $child - $setting - $value - - - $setting - $this->getFilterChain()->filter($values['result']) - - - $model - - - $values - - $options['feed_type'] @@ -1754,9 +1575,6 @@ - - void - $jsonpCallback @@ -1783,6 +1601,9 @@ $children $values + + (int) $e->getCode() + (bool) $mergeUnnamedChildren (string) $callback @@ -1944,8 +1765,7 @@ false false - - $value + $value $value $value @@ -1958,8 +1778,7 @@ $this->paths - - (bool) $flag + (bool) $flag (string) $defaultSuffix @@ -2015,34 +1834,6 @@ plugin - - - $data - $stat - - - $mode - $offset - $opened_path - $options - $whence - - - $this->pos - $this->pos - $this->pos - - - $offset - $offset - $offset - - - break; - break; - break; - - ArrayIterator::class @@ -2201,61 +1992,6 @@ $test - - - $plugin - $plugin - $this->mvcPluginClass - - - FlashMessenger - new FlashMessenger() - new FlashMessenger() - new FlashMessenger() - new FlashMessenger() - new FlashMessenger() - new FlashMessenger() - - - $displayInfo - $displayInfo - $displayInfo - $displayInfo - $helper - $helper - $helper - $helper - $helperPluginManager - $helperPluginManager - $helperPluginManager - $helperPluginManager - - - get - get - get - get - render - render - renderCurrent - renderCurrent - - - hasCurrentErrorMessages - hasCurrentInfoMessages - hasCurrentMessages - hasCurrentSuccessMessages - hasErrorMessages - hasInfoMessages - hasMessages - hasSuccessMessages - hasWarningMessages - render - render - renderCurrent - renderCurrent - - $value @@ -2595,11 +2331,6 @@ renderTitle - - - HtmlFlash - - $escape($value) @@ -3163,29 +2894,23 @@ $serviceConfig $test - + $router $serviceConfig $test $test - $test $urlHelper $urlHelper - $urlHelper - $viewHelpers $viewHelpers $viewHelpers - - $urlHelper('test') + $urlHelper('test') $urlHelper('test', [], ['force_canonical' => true]) - + bootstrap bootstrap - bootstrap - get get get setRequestUri @@ -3205,8 +2930,7 @@ - - $target + $target From ea410f1a1608e82c6ce2555eb03676aa444b9f61 Mon Sep 17 00:00:00 2001 From: George Steel Date: Tue, 18 Apr 2023 16:30:01 +0100 Subject: [PATCH 31/58] Update lock and baseline post merge-up Signed-off-by: George Steel --- composer.lock | 256 +++++++------- psalm-baseline.xml | 835 +++++++++++++++------------------------------ 2 files changed, 413 insertions(+), 678 deletions(-) diff --git a/composer.lock b/composer.lock index 957b981e6..a2579e6b1 100644 --- a/composer.lock +++ b/composer.lock @@ -1187,16 +1187,16 @@ }, { "name": "fidry/cpu-core-counter", - "version": "0.4.1", + "version": "0.5.1", "source": { "type": "git", "url": "https://github.com/theofidry/cpu-core-counter.git", - "reference": "79261cc280aded96d098e1b0e0ba0c4881b432c2" + "reference": "b58e5a3933e541dc286cc91fc4f3898bbc6f1623" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/theofidry/cpu-core-counter/zipball/79261cc280aded96d098e1b0e0ba0c4881b432c2", - "reference": "79261cc280aded96d098e1b0e0ba0c4881b432c2", + "url": "https://api.github.com/repos/theofidry/cpu-core-counter/zipball/b58e5a3933e541dc286cc91fc4f3898bbc6f1623", + "reference": "b58e5a3933e541dc286cc91fc4f3898bbc6f1623", "shasum": "" }, "require": { @@ -1236,7 +1236,7 @@ ], "support": { "issues": "https://github.com/theofidry/cpu-core-counter/issues", - "source": "https://github.com/theofidry/cpu-core-counter/tree/0.4.1" + "source": "https://github.com/theofidry/cpu-core-counter/tree/0.5.1" }, "funding": [ { @@ -1244,7 +1244,7 @@ "type": "github" } ], - "time": "2022-12-16T22:01:02+00:00" + "time": "2022-12-24T12:35:10+00:00" }, { "name": "laminas/laminas-authentication", @@ -1671,16 +1671,16 @@ }, { "name": "laminas/laminas-i18n", - "version": "2.21.0", + "version": "2.22.1", "source": { "type": "git", "url": "https://github.com/laminas/laminas-i18n.git", - "reference": "fbd2d0373aaced4769cba2bf3d1425d55f68abb1" + "reference": "075bec49f777698c6fc229eecefbe7a2364cd18e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-i18n/zipball/fbd2d0373aaced4769cba2bf3d1425d55f68abb1", - "reference": "fbd2d0373aaced4769cba2bf3d1425d55f68abb1", + "url": "https://api.github.com/repos/laminas/laminas-i18n/zipball/075bec49f777698c6fc229eecefbe7a2364cd18e", + "reference": "075bec49f777698c6fc229eecefbe7a2364cd18e", "shasum": "" }, "require": { @@ -1698,7 +1698,7 @@ "laminas/laminas-cache": "^3.8", "laminas/laminas-cache-storage-adapter-memory": "^2.2.0", "laminas/laminas-cache-storage-deprecated-factory": "^1.0.1", - "laminas/laminas-coding-standard": "~2.4.0", + "laminas/laminas-coding-standard": "~2.5.0", "laminas/laminas-config": "^3.8.0", "laminas/laminas-eventmanager": "^3.7", "laminas/laminas-filter": "^2.28.1", @@ -1753,7 +1753,7 @@ "type": "community_bridge" } ], - "time": "2022-12-02T17:15:52+00:00" + "time": "2023-03-31T12:31:38+00:00" }, { "name": "laminas/laminas-loader", @@ -1885,16 +1885,16 @@ }, { "name": "laminas/laminas-mvc", - "version": "3.6.0", + "version": "3.6.1", "source": { "type": "git", "url": "https://github.com/laminas/laminas-mvc.git", - "reference": "c54eaebe3810feaca834cc38ef0a962c89ff2431" + "reference": "f12e801c31c04a4b35017354ff84070f5573879f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-mvc/zipball/c54eaebe3810feaca834cc38ef0a962c89ff2431", - "reference": "c54eaebe3810feaca834cc38ef0a962c89ff2431", + "url": "https://api.github.com/repos/laminas/laminas-mvc/zipball/f12e801c31c04a4b35017354ff84070f5573879f", + "reference": "f12e801c31c04a4b35017354ff84070f5573879f", "shasum": "" }, "require": { @@ -1902,8 +1902,8 @@ "laminas/laminas-eventmanager": "^3.4", "laminas/laminas-http": "^2.15", "laminas/laminas-modulemanager": "^2.8", - "laminas/laminas-router": "^3.5", - "laminas/laminas-servicemanager": "^3.7", + "laminas/laminas-router": "^3.11.1", + "laminas/laminas-servicemanager": "^3.20.0", "laminas/laminas-stdlib": "^3.6", "laminas/laminas-view": "^2.14", "php": "~8.0.0 || ~8.1.0 || ~8.2.0" @@ -1912,14 +1912,12 @@ "zendframework/zend-mvc": "*" }, "require-dev": { - "http-interop/http-middleware": "^0.4.1", "laminas/laminas-coding-standard": "^2.4.0", "laminas/laminas-json": "^3.3", - "laminas/laminas-psr7bridge": "^1.8", - "laminas/laminas-stratigility": ">=2.0.1 <2.2", "phpspec/prophecy": "^1.15.0", "phpspec/prophecy-phpunit": "^2.0.1", - "phpunit/phpunit": "^9.5.25" + "phpunit/phpunit": "^9.5.25", + "webmozart/assert": "^1.11" }, "suggest": { "laminas/laminas-json": "(^2.6.1 || ^3.0) To auto-deserialize JSON body content in AbstractRestfulController extensions, when json_decode is unavailable", @@ -1964,7 +1962,7 @@ "type": "community_bridge" } ], - "time": "2022-12-05T14:02:56+00:00" + "time": "2023-03-15T10:21:03+00:00" }, { "name": "laminas/laminas-mvc-i18n", @@ -2206,16 +2204,16 @@ }, { "name": "laminas/laminas-permissions-acl", - "version": "2.13.0", + "version": "2.14.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-permissions-acl.git", - "reference": "a13454dc3013cdcb388c95c418866e93dc781300" + "reference": "86cecb540cf8f2e088d70d8acef1fc9203ed5023" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-permissions-acl/zipball/a13454dc3013cdcb388c95c418866e93dc781300", - "reference": "a13454dc3013cdcb388c95c418866e93dc781300", + "url": "https://api.github.com/repos/laminas/laminas-permissions-acl/zipball/86cecb540cf8f2e088d70d8acef1fc9203ed5023", + "reference": "86cecb540cf8f2e088d70d8acef1fc9203ed5023", "shasum": "" }, "require": { @@ -2226,8 +2224,9 @@ "zendframework/zend-permissions-acl": "*" }, "require-dev": { - "laminas/laminas-coding-standard": "~2.4.0", + "laminas/laminas-coding-standard": "~2.5.0", "laminas/laminas-servicemanager": "^3.19", + "phpbench/phpbench": "^1.2", "phpunit/phpunit": "^9.5.26", "psalm/plugin-phpunit": "^0.18.0", "vimeo/psalm": "^5.0" @@ -2265,7 +2264,7 @@ "type": "community_bridge" } ], - "time": "2022-12-01T10:29:36+00:00" + "time": "2023-02-01T16:19:54+00:00" }, { "name": "laminas/laminas-router", @@ -2483,16 +2482,16 @@ }, { "name": "myclabs/deep-copy", - "version": "1.11.0", + "version": "1.11.1", "source": { "type": "git", "url": "https://github.com/myclabs/DeepCopy.git", - "reference": "14daed4296fae74d9e3201d2c4925d1acb7aa614" + "reference": "7284c22080590fb39f2ffa3e9057f10a4ddd0e0c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/14daed4296fae74d9e3201d2c4925d1acb7aa614", - "reference": "14daed4296fae74d9e3201d2c4925d1acb7aa614", + "url": "https://api.github.com/repos/myclabs/DeepCopy/zipball/7284c22080590fb39f2ffa3e9057f10a4ddd0e0c", + "reference": "7284c22080590fb39f2ffa3e9057f10a4ddd0e0c", "shasum": "" }, "require": { @@ -2530,7 +2529,7 @@ ], "support": { "issues": "https://github.com/myclabs/DeepCopy/issues", - "source": "https://github.com/myclabs/DeepCopy/tree/1.11.0" + "source": "https://github.com/myclabs/DeepCopy/tree/1.11.1" }, "funding": [ { @@ -2538,20 +2537,20 @@ "type": "tidelift" } ], - "time": "2022-03-03T13:19:32+00:00" + "time": "2023-03-08T13:26:56+00:00" }, { "name": "netresearch/jsonmapper", - "version": "v4.1.0", + "version": "v4.2.0", "source": { "type": "git", "url": "https://github.com/cweiske/jsonmapper.git", - "reference": "cfa81ea1d35294d64adb9c68aa4cb9e92400e53f" + "reference": "f60565f8c0566a31acf06884cdaa591867ecc956" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/cweiske/jsonmapper/zipball/cfa81ea1d35294d64adb9c68aa4cb9e92400e53f", - "reference": "cfa81ea1d35294d64adb9c68aa4cb9e92400e53f", + "url": "https://api.github.com/repos/cweiske/jsonmapper/zipball/f60565f8c0566a31acf06884cdaa591867ecc956", + "reference": "f60565f8c0566a31acf06884cdaa591867ecc956", "shasum": "" }, "require": { @@ -2587,22 +2586,22 @@ "support": { "email": "cweiske@cweiske.de", "issues": "https://github.com/cweiske/jsonmapper/issues", - "source": "https://github.com/cweiske/jsonmapper/tree/v4.1.0" + "source": "https://github.com/cweiske/jsonmapper/tree/v4.2.0" }, - "time": "2022-12-08T20:46:14+00:00" + "time": "2023-04-09T17:37:40+00:00" }, { "name": "nikic/php-parser", - "version": "v4.15.3", + "version": "v4.15.4", "source": { "type": "git", "url": "https://github.com/nikic/PHP-Parser.git", - "reference": "570e980a201d8ed0236b0a62ddf2c9cbb2034039" + "reference": "6bb5176bc4af8bcb7d926f88718db9b96a2d4290" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/570e980a201d8ed0236b0a62ddf2c9cbb2034039", - "reference": "570e980a201d8ed0236b0a62ddf2c9cbb2034039", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/6bb5176bc4af8bcb7d926f88718db9b96a2d4290", + "reference": "6bb5176bc4af8bcb7d926f88718db9b96a2d4290", "shasum": "" }, "require": { @@ -2643,9 +2642,9 @@ ], "support": { "issues": "https://github.com/nikic/PHP-Parser/issues", - "source": "https://github.com/nikic/PHP-Parser/tree/v4.15.3" + "source": "https://github.com/nikic/PHP-Parser/tree/v4.15.4" }, - "time": "2023-01-16T22:05:37+00:00" + "time": "2023-03-05T19:49:14+00:00" }, { "name": "phar-io/manifest", @@ -2969,23 +2968,23 @@ }, { "name": "phpunit/php-code-coverage", - "version": "9.2.24", + "version": "9.2.26", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "2cf940ebc6355a9d430462811b5aaa308b174bed" + "reference": "443bc6912c9bd5b409254a40f4b0f4ced7c80ea1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/2cf940ebc6355a9d430462811b5aaa308b174bed", - "reference": "2cf940ebc6355a9d430462811b5aaa308b174bed", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/443bc6912c9bd5b409254a40f4b0f4ced7c80ea1", + "reference": "443bc6912c9bd5b409254a40f4b0f4ced7c80ea1", "shasum": "" }, "require": { "ext-dom": "*", "ext-libxml": "*", "ext-xmlwriter": "*", - "nikic/php-parser": "^4.14", + "nikic/php-parser": "^4.15", "php": ">=7.3", "phpunit/php-file-iterator": "^3.0.3", "phpunit/php-text-template": "^2.0.2", @@ -3000,8 +2999,8 @@ "phpunit/phpunit": "^9.3" }, "suggest": { - "ext-pcov": "*", - "ext-xdebug": "*" + "ext-pcov": "PHP extension that provides line coverage", + "ext-xdebug": "PHP extension that provides line coverage as well as branch and path coverage" }, "type": "library", "extra": { @@ -3034,7 +3033,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", - "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.24" + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/9.2.26" }, "funding": [ { @@ -3042,7 +3041,7 @@ "type": "github" } ], - "time": "2023-01-26T08:26:55+00:00" + "time": "2023-03-06T12:58:08+00:00" }, { "name": "phpunit/php-file-iterator", @@ -3287,16 +3286,16 @@ }, { "name": "phpunit/phpunit", - "version": "9.5.28", + "version": "9.6.7", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "954ca3113a03bf780d22f07bf055d883ee04b65e" + "reference": "c993f0d3b0489ffc42ee2fe0bd645af1538a63b2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/954ca3113a03bf780d22f07bf055d883ee04b65e", - "reference": "954ca3113a03bf780d22f07bf055d883ee04b65e", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/c993f0d3b0489ffc42ee2fe0bd645af1538a63b2", + "reference": "c993f0d3b0489ffc42ee2fe0bd645af1538a63b2", "shasum": "" }, "require": { @@ -3329,8 +3328,8 @@ "sebastian/version": "^3.0.2" }, "suggest": { - "ext-soap": "*", - "ext-xdebug": "*" + "ext-soap": "To be able to generate mocks based on WSDL files", + "ext-xdebug": "PHP extension that provides line coverage as well as branch and path coverage" }, "bin": [ "phpunit" @@ -3338,7 +3337,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "9.5-dev" + "dev-master": "9.6-dev" } }, "autoload": { @@ -3369,7 +3368,8 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", - "source": "https://github.com/sebastianbergmann/phpunit/tree/9.5.28" + "security": "https://github.com/sebastianbergmann/phpunit/security/policy", + "source": "https://github.com/sebastianbergmann/phpunit/tree/9.6.7" }, "funding": [ { @@ -3385,7 +3385,7 @@ "type": "tidelift" } ], - "time": "2023-01-14T12:32:24+00:00" + "time": "2023-04-14T08:58:40+00:00" }, { "name": "psalm/plugin-phpunit", @@ -3449,25 +3449,25 @@ }, { "name": "psr/http-message", - "version": "1.0.1", + "version": "1.1", "source": { "type": "git", "url": "https://github.com/php-fig/http-message.git", - "reference": "f6561bf28d520154e4b0ec72be95418abe6d9363" + "reference": "cb6ce4845ce34a8ad9e68117c10ee90a29919eba" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/http-message/zipball/f6561bf28d520154e4b0ec72be95418abe6d9363", - "reference": "f6561bf28d520154e4b0ec72be95418abe6d9363", + "url": "https://api.github.com/repos/php-fig/http-message/zipball/cb6ce4845ce34a8ad9e68117c10ee90a29919eba", + "reference": "cb6ce4845ce34a8ad9e68117c10ee90a29919eba", "shasum": "" }, "require": { - "php": ">=5.3.0" + "php": "^7.2 || ^8.0" }, "type": "library", "extra": { "branch-alias": { - "dev-master": "1.0.x-dev" + "dev-master": "1.1.x-dev" } }, "autoload": { @@ -3496,9 +3496,9 @@ "response" ], "support": { - "source": "https://github.com/php-fig/http-message/tree/master" + "source": "https://github.com/php-fig/http-message/tree/1.1" }, - "time": "2016-08-06T14:39:51+00:00" + "time": "2023-04-04T09:50:52+00:00" }, { "name": "psr/log", @@ -3916,16 +3916,16 @@ }, { "name": "sebastian/environment", - "version": "5.1.4", + "version": "5.1.5", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/environment.git", - "reference": "1b5dff7bb151a4db11d49d90e5408e4e938270f7" + "reference": "830c43a844f1f8d5b7a1f6d6076b784454d8b7ed" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/1b5dff7bb151a4db11d49d90e5408e4e938270f7", - "reference": "1b5dff7bb151a4db11d49d90e5408e4e938270f7", + "url": "https://api.github.com/repos/sebastianbergmann/environment/zipball/830c43a844f1f8d5b7a1f6d6076b784454d8b7ed", + "reference": "830c43a844f1f8d5b7a1f6d6076b784454d8b7ed", "shasum": "" }, "require": { @@ -3967,7 +3967,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/environment/issues", - "source": "https://github.com/sebastianbergmann/environment/tree/5.1.4" + "source": "https://github.com/sebastianbergmann/environment/tree/5.1.5" }, "funding": [ { @@ -3975,7 +3975,7 @@ "type": "github" } ], - "time": "2022-04-03T09:37:03+00:00" + "time": "2023-02-03T06:03:51+00:00" }, { "name": "sebastian/exporter", @@ -4289,16 +4289,16 @@ }, { "name": "sebastian/recursion-context", - "version": "4.0.4", + "version": "4.0.5", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/recursion-context.git", - "reference": "cd9d8cf3c5804de4341c283ed787f099f5506172" + "reference": "e75bd0f07204fec2a0af9b0f3cfe97d05f92efc1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/cd9d8cf3c5804de4341c283ed787f099f5506172", - "reference": "cd9d8cf3c5804de4341c283ed787f099f5506172", + "url": "https://api.github.com/repos/sebastianbergmann/recursion-context/zipball/e75bd0f07204fec2a0af9b0f3cfe97d05f92efc1", + "reference": "e75bd0f07204fec2a0af9b0f3cfe97d05f92efc1", "shasum": "" }, "require": { @@ -4337,10 +4337,10 @@ } ], "description": "Provides functionality to recursively process PHP variables", - "homepage": "http://www.github.com/sebastianbergmann/recursion-context", + "homepage": "https://github.com/sebastianbergmann/recursion-context", "support": { "issues": "https://github.com/sebastianbergmann/recursion-context/issues", - "source": "https://github.com/sebastianbergmann/recursion-context/tree/4.0.4" + "source": "https://github.com/sebastianbergmann/recursion-context/tree/4.0.5" }, "funding": [ { @@ -4348,7 +4348,7 @@ "type": "github" } ], - "time": "2020-10-26T13:17:30+00:00" + "time": "2023-02-03T06:07:39+00:00" }, { "name": "sebastian/resource-operations", @@ -4407,16 +4407,16 @@ }, { "name": "sebastian/type", - "version": "3.2.0", + "version": "3.2.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/type.git", - "reference": "fb3fe09c5f0bae6bc27ef3ce933a1e0ed9464b6e" + "reference": "75e2c2a32f5e0b3aef905b9ed0b179b953b3d7c7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/fb3fe09c5f0bae6bc27ef3ce933a1e0ed9464b6e", - "reference": "fb3fe09c5f0bae6bc27ef3ce933a1e0ed9464b6e", + "url": "https://api.github.com/repos/sebastianbergmann/type/zipball/75e2c2a32f5e0b3aef905b9ed0b179b953b3d7c7", + "reference": "75e2c2a32f5e0b3aef905b9ed0b179b953b3d7c7", "shasum": "" }, "require": { @@ -4451,7 +4451,7 @@ "homepage": "https://github.com/sebastianbergmann/type", "support": { "issues": "https://github.com/sebastianbergmann/type/issues", - "source": "https://github.com/sebastianbergmann/type/tree/3.2.0" + "source": "https://github.com/sebastianbergmann/type/tree/3.2.1" }, "funding": [ { @@ -4459,7 +4459,7 @@ "type": "github" } ], - "time": "2022-09-12T14:47:03+00:00" + "time": "2023-02-03T06:13:03+00:00" }, { "name": "sebastian/version", @@ -4577,26 +4577,25 @@ }, { "name": "spatie/array-to-xml", - "version": "2.17.1", + "version": "3.1.5", "source": { "type": "git", "url": "https://github.com/spatie/array-to-xml.git", - "reference": "5cbec9c6ab17e320c58a259f0cebe88bde4a7c46" + "reference": "13f76acef5362d15c71ae1ac6350cc3df5e25e43" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/spatie/array-to-xml/zipball/5cbec9c6ab17e320c58a259f0cebe88bde4a7c46", - "reference": "5cbec9c6ab17e320c58a259f0cebe88bde4a7c46", + "url": "https://api.github.com/repos/spatie/array-to-xml/zipball/13f76acef5362d15c71ae1ac6350cc3df5e25e43", + "reference": "13f76acef5362d15c71ae1ac6350cc3df5e25e43", "shasum": "" }, "require": { "ext-dom": "*", - "php": "^7.4|^8.0" + "php": "^8.0" }, "require-dev": { "mockery/mockery": "^1.2", "pestphp/pest": "^1.21", - "phpunit/phpunit": "^9.0", "spatie/pest-plugin-snapshots": "^1.1" }, "type": "library", @@ -4625,7 +4624,7 @@ "xml" ], "support": { - "source": "https://github.com/spatie/array-to-xml/tree/2.17.1" + "source": "https://github.com/spatie/array-to-xml/tree/3.1.5" }, "funding": [ { @@ -4637,20 +4636,20 @@ "type": "github" } ], - "time": "2022-12-26T08:22:07+00:00" + "time": "2022-12-24T13:43:51+00:00" }, { "name": "squizlabs/php_codesniffer", - "version": "3.7.1", + "version": "3.7.2", "source": { "type": "git", "url": "https://github.com/squizlabs/PHP_CodeSniffer.git", - "reference": "1359e176e9307e906dc3d890bcc9603ff6d90619" + "reference": "ed8e00df0a83aa96acf703f8c2979ff33341f879" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/1359e176e9307e906dc3d890bcc9603ff6d90619", - "reference": "1359e176e9307e906dc3d890bcc9603ff6d90619", + "url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/ed8e00df0a83aa96acf703f8c2979ff33341f879", + "reference": "ed8e00df0a83aa96acf703f8c2979ff33341f879", "shasum": "" }, "require": { @@ -4686,14 +4685,15 @@ "homepage": "https://github.com/squizlabs/PHP_CodeSniffer", "keywords": [ "phpcs", - "standards" + "standards", + "static analysis" ], "support": { "issues": "https://github.com/squizlabs/PHP_CodeSniffer/issues", "source": "https://github.com/squizlabs/PHP_CodeSniffer", "wiki": "https://github.com/squizlabs/PHP_CodeSniffer/wiki" }, - "time": "2022-06-18T07:21:10+00:00" + "time": "2023-02-22T23:07:41+00:00" }, { "name": "symfony/console", @@ -5470,22 +5470,22 @@ }, { "name": "vimeo/psalm", - "version": "5.6.0", + "version": "5.9.0", "source": { "type": "git", "url": "https://github.com/vimeo/psalm.git", - "reference": "e784128902dfe01d489c4123d69918a9f3c1eac5" + "reference": "8b9ad1eb9e8b7d3101f949291da2b9f7767cd163" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/vimeo/psalm/zipball/e784128902dfe01d489c4123d69918a9f3c1eac5", - "reference": "e784128902dfe01d489c4123d69918a9f3c1eac5", + "url": "https://api.github.com/repos/vimeo/psalm/zipball/8b9ad1eb9e8b7d3101f949291da2b9f7767cd163", + "reference": "8b9ad1eb9e8b7d3101f949291da2b9f7767cd163", "shasum": "" }, "require": { "amphp/amp": "^2.4.2", "amphp/byte-stream": "^1.5", - "composer/package-versions-deprecated": "^1.10.0", + "composer-runtime-api": "^2", "composer/semver": "^1.4 || ^2.0 || ^3.0", "composer/xdebug-handler": "^2.0 || ^3.0", "dnoegel/php-xdg-base-dir": "^0.1.1", @@ -5498,12 +5498,12 @@ "ext-tokenizer": "*", "felixfbecker/advanced-json-rpc": "^3.1", "felixfbecker/language-server-protocol": "^1.5.2", - "fidry/cpu-core-counter": "^0.4.0", + "fidry/cpu-core-counter": "^0.4.1 || ^0.5.1", "netresearch/jsonmapper": "^1.0 || ^2.0 || ^3.0 || ^4.0", - "nikic/php-parser": "^4.13", + "nikic/php-parser": "^4.14", "php": "^7.4 || ~8.0.0 || ~8.1.0 || ~8.2.0", "sebastian/diff": "^4.0 || ^5.0", - "spatie/array-to-xml": "^2.17.0", + "spatie/array-to-xml": "^2.17.0 || ^3.0", "symfony/console": "^4.1.6 || ^5.0 || ^6.0", "symfony/filesystem": "^5.4 || ^6.0" }, @@ -5511,14 +5511,15 @@ "psalm/psalm": "self.version" }, "require-dev": { + "amphp/phpunit-util": "^2.0", "bamarni/composer-bin-plugin": "^1.4", - "brianium/paratest": "^6.0", + "brianium/paratest": "^6.9", "ext-curl": "*", "mockery/mockery": "^1.5", "nunomaduro/mock-final-classes": "^1.1", "php-parallel-lint/php-parallel-lint": "^1.2", "phpstan/phpdoc-parser": "^1.6", - "phpunit/phpunit": "^9.5", + "phpunit/phpunit": "^9.6", "psalm/plugin-mockery": "^1.1", "psalm/plugin-phpunit": "^0.18", "slevomat/coding-standard": "^8.4", @@ -5564,34 +5565,35 @@ "keywords": [ "code", "inspection", - "php" + "php", + "static analysis" ], "support": { "issues": "https://github.com/vimeo/psalm/issues", - "source": "https://github.com/vimeo/psalm/tree/5.6.0" + "source": "https://github.com/vimeo/psalm/tree/5.9.0" }, - "time": "2023-01-23T20:32:47+00:00" + "time": "2023-03-29T21:38:21+00:00" }, { "name": "webimpress/coding-standard", - "version": "1.2.4", + "version": "1.3.1", "source": { "type": "git", "url": "https://github.com/webimpress/coding-standard.git", - "reference": "cd0c4b0b97440c337c1f7da17b524674ca2f9ca9" + "reference": "b26557e2386711ecb74f22718f4b4bde5ddbc899" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/webimpress/coding-standard/zipball/cd0c4b0b97440c337c1f7da17b524674ca2f9ca9", - "reference": "cd0c4b0b97440c337c1f7da17b524674ca2f9ca9", + "url": "https://api.github.com/repos/webimpress/coding-standard/zipball/b26557e2386711ecb74f22718f4b4bde5ddbc899", + "reference": "b26557e2386711ecb74f22718f4b4bde5ddbc899", "shasum": "" }, "require": { "php": "^7.3 || ^8.0", - "squizlabs/php_codesniffer": "^3.6.2" + "squizlabs/php_codesniffer": "^3.7.2" }, "require-dev": { - "phpunit/phpunit": "^9.5.13" + "phpunit/phpunit": "^9.6.4" }, "type": "phpcodesniffer-standard", "extra": { @@ -5617,7 +5619,7 @@ ], "support": { "issues": "https://github.com/webimpress/coding-standard/issues", - "source": "https://github.com/webimpress/coding-standard/tree/1.2.4" + "source": "https://github.com/webimpress/coding-standard/tree/1.3.1" }, "funding": [ { @@ -5625,7 +5627,7 @@ "type": "github" } ], - "time": "2022-02-15T19:52:12+00:00" + "time": "2023-03-09T15:05:18+00:00" }, { "name": "webimpress/safe-writer", diff --git a/psalm-baseline.xml b/psalm-baseline.xml index 2077143a3..2f626aaf9 100644 --- a/psalm-baseline.xml +++ b/psalm-baseline.xml @@ -1,12 +1,12 @@ - + $templatePath $file - $file->getExtension() + getExtension()]]> $templatePath @@ -30,8 +30,6 @@ $closingBracket $closingBracket $closingBracket - $closingBracket - $closingBracket $val @@ -63,24 +61,24 @@ Iterator - $this->data[$this->name] - $this->data[$this->name] + data[$this->name]]]> + data[$this->name]]]> - $this->data[$this->name][$this->key()] - $this->data[$this->name][$this->key()] + data[$this->name][$this->key()]]]> + data[$this->name][$this->key()]]]> array int - $this->pointers[$this->name] - $this->pointers[$this->name] + pointers[$this->name]]]> + pointers[$this->name]]]> - $this->data[$this->name] - $this->pointers[$this->name] + data[$this->name]]]> + pointers[$this->name]]]> @@ -100,7 +98,7 @@ $vars - $vars->$key + $key]]> $view @@ -119,16 +117,16 @@ null === static::$registeredDoctypes - $this->registry['doctypes'][$type] + registry['doctypes'][$type]]]> array string - $doctypes[$this->getDoctype()] - $this->registry['doctype'] - $this->registry['doctypes'] + getDoctype()]]]> + registry['doctype']]]> + registry['doctypes']]]> $registry @@ -140,46 +138,6 @@ $value[$k] - - - null === $this->pluginFlashMessenger - - - $item - - - $escapeHtmlHelper - $pluginFlashMessenger - - - $item - $messagesToPrint - - - $classes - $classes - - - $messagesToPrint[] - $messagesToPrint[] - - - $classes - $classes - $messagesToPrint[] - $messagesToPrint[] - $this->escapeHtmlHelper - - - (bool) $autoEscape - (string) $messageCloseString - (string) $messageOpenFormat - (string) $messageSeparatorString - - - $this->escapeHtmlHelper - - $flag === null @@ -202,10 +160,10 @@ string - $this->options['default_img'] - $this->options['img_size'] - $this->options['rating'] - $this->options['secure'] + options['default_img']]]> + options['img_size']]]> + options['rating']]]> + options['secure']]]> (bool) $flag @@ -220,7 +178,7 @@ $item - $this->getContainer()->set($value) + getContainer()->set($value)]]> HeadLink @@ -238,9 +196,9 @@ $index $item $item - $this->autoEscape ? $this->escapeAttribute($attributes[$itemKey]) : $attributes[$itemKey] - $this->autoEscape ? $this->escapeAttribute($value) : $value - $this->getSeparator() + autoEscape ? $this->escapeAttribute($attributes[$itemKey]) : $attributes[$itemKey]]]> + autoEscape ? $this->escapeAttribute($value) : $value]]> + getSeparator()]]> $value @@ -275,8 +233,8 @@ $indent - $item->href - $item->rel + href]]> + rel]]> call_user_func_array([$this, '__invoke'], func_get_args()) @@ -295,7 +253,7 @@ $index - $this->view + view]]> (string) $conditionalStylesheet @@ -324,14 +282,14 @@ $args[2] $index $item - $item->$type - $item->content - $item->type + $type]]> + content]]> + type]]> $key - $this->autoEscape ? $this->escapeAttribute($item->$type) : $item->$type - $this->autoEscape ? $this->escapeAttribute($item->content) : $item->content - $this->autoEscape ? $this->escapeAttribute($value) : $value - $this->getSeparator() + autoEscape ? $this->escapeAttribute($item->$type) : $item->$type]]> + autoEscape ? $this->escapeAttribute($item->content) : $item->content]]> + autoEscape ? $this->escapeAttribute($value) : $value]]> + getSeparator()]]> $type $value @@ -361,8 +319,8 @@ $indent - $item->type - $item->{$item->type} + type]]> + {$item->type}]]> parent::__call($method, $args) @@ -372,14 +330,14 @@ $value - $this->offsetSet($index, $item) + offsetSet($index, $item)]]> $index $index - $this->view + view]]> plugin @@ -408,13 +366,13 @@ $indent $index $index - $item->attributes - $item->attributes['conditional'] - $item->type - $item->type + attributes]]> + attributes['conditional']]]> + type]]> + type]]> $key - $this->autoEscape ? $this->escapeAttribute($value) : $value - $this->getSeparator() + autoEscape ? $this->escapeAttribute($value) : $value]]> + getSeparator()]]> $value @@ -425,7 +383,7 @@ $item $item $key - $this->captureType + captureType]]> $type $useCdata $value @@ -438,16 +396,16 @@ isXhtml - $item->attributes['conditional'] - $item->source + attributes['conditional']]]> + source]]> $type - $item->attributes - $item->attributes - $item->source - $item->source - $item->type + attributes]]> + attributes]]> + source]]> + source]]> + type]]> parent::__call($method, $args) @@ -468,7 +426,7 @@ (bool) $flag - (null !== $spec) && is_string($spec) + is_string($spec) @@ -486,11 +444,11 @@ $content $enc - $escaper->escapeHtmlAttr($value) + escapeHtmlAttr($value)]]> $indent $index $item - $item->attributes['conditional'] + attributes['conditional']]]> $key $value $value @@ -499,7 +457,7 @@ $attributes['media'] - $item->attributes['conditional'] + attributes['conditional']]]> $content @@ -517,8 +475,8 @@ $indent $indent - $item->attributes['conditional'] - $item->content + attributes['conditional']]]> + content]]> $index @@ -537,7 +495,7 @@ $captureType - (null !== $content) && is_string($content) + is_string($content) @@ -553,7 +511,7 @@ $item - static fn($item) => $item + $item]]> $item @@ -579,26 +537,6 @@ translate - - - $htmlObject - - - $htmlObject($data, self::TYPE, $attribs, $params, $content) - - - string - - - $htmlObject($data, self::TYPE, $attribs, $params, $content) - - - plugin - - - plugin - - is_array($content) @@ -631,26 +569,6 @@ plugin - - - $htmlObject - - - $htmlObject($data, self::TYPE, $attribs, $params, $content) - - - string - - - $htmlObject($data, self::TYPE, $attribs, $params, $content) - - - plugin - - - plugin - - $value @@ -662,7 +580,7 @@ $value - $this->view + view]]> (bool) $useNamespaces @@ -681,17 +599,6 @@ InlineScript - - - $response - - - null - - - $this->response instanceof Response - - plugin @@ -729,10 +636,10 @@ - ! is_int($this->minDepth) + minDepth)]]> ! is_string($message) $container instanceof AbstractContainer - null === $this->container + container]]> AbstractHelper @@ -763,8 +670,8 @@ $minDepth - $page->getTextDomain() - $page->getTextDomain() + getTextDomain()]]> + getTextDomain()]]> $container @@ -774,12 +681,15 @@ bool + string $label - $results->last() + $message + $message + last()]]> $events @@ -788,7 +698,7 @@ strrpos($prefix, '\\') - $page->getTitle() + getTitle()]]> $maxDepth @@ -806,10 +716,10 @@ (string) $indent - $this->acl === null && static::$defaultAcl !== null + acl === null && static::$defaultAcl !== null]]> is_int($maxDepth) is_int($minDepth) - null !== $this->container + container]]> static::$defaultAcl !== null @@ -830,8 +740,8 @@ null === $partial - $this->renderPartialModel($params, $container, $partial) - $this->renderPartialModel([], $container, $partial) + renderPartialModel($params, $container, $partial)]]> + renderPartialModel([], $container, $partial)]]> string @@ -842,8 +752,8 @@ $active - $active->getLabel() - $active->getTextDomain() + getLabel()]]> + getTextDomain()]]> $model['pages'] $partial[0] @@ -908,7 +818,7 @@ $intermediate $page $page - $page->$meth() + $meth()]]> $type @@ -948,7 +858,7 @@ (int) $renderFlag - $this->root + root]]> null === $container @@ -979,8 +889,8 @@ null === $partial - $this->renderPartialModel($params, $container, $partial) - $this->renderPartialModel([], $container, $partial) + renderPartialModel($params, $container, $partial)]]> + renderPartialModel([], $container, $partial)]]> string @@ -1008,8 +918,8 @@ $options['ulClass'] $page $page - $page->getTextDomain() - $page->getTextDomain() + getTextDomain()]]> + getTextDomain()]]> $partial[0] $subPage @@ -1052,7 +962,7 @@ $container - $page->getTitle() + getTitle()]]> $minDepth @@ -1115,7 +1025,7 @@ $page $priority $serverUrlHelper - $this->serverUrl + serverUrl]]> $basePathHelper() @@ -1128,8 +1038,8 @@ $escaper($string) - $this->serverUrl - $this->serverUrl + serverUrl]]> + serverUrl]]> $container @@ -1155,7 +1065,7 @@ (string) $href - isset($this->serverUrl) + serverUrl)]]> plugin @@ -1184,7 +1094,7 @@ $partialHelper($partial[0], $pages) - $this->view->paginator + view->paginator]]> plugin @@ -1232,13 +1142,13 @@ $item - $this->objectKey + objectKey]]> array - $values->toArray() + toArray()]]> $name @@ -1256,23 +1166,22 @@ - new $this->containerClass($value) + containerClass($value)]]> - $this->items[$key] + items[$key]]]> AbstractContainer - $this->items + items]]> (string) $key (string) $key (string) $key (string) $key - (string) $name @@ -1318,15 +1227,15 @@ (string) $separator - null !== $this->captureKey + captureKey]]> - new $this->containerClass() + containerClass()]]> - $this->container + container]]> ArrayAccess @@ -1345,8 +1254,8 @@ escapeHtmlAttr - $this->getEscaper()->escapeHtml((string) $string) - $this->getEscaper()->escapeHtmlAttr((string) $string) + getEscaper()->escapeHtml((string) $string)]]> + getEscaper()->escapeHtmlAttr((string) $string)]]> AbstractContainer @@ -1358,7 +1267,7 @@ null - new $this->containerClass() + containerClass()]]> (bool) $autoEscape @@ -1366,24 +1275,21 @@ (string) $string - null !== $this->container + container]]> - - null === static::$instance - - new $this->containerClass($value) + containerClass($value)]]> - $this->items[$key] + items[$key]]]> AbstractContainer - $this->items[$key] + items[$key]]]> AbstractContainer @@ -1395,9 +1301,6 @@ (string) $key (string) $key - - new static() - @@ -1406,7 +1309,7 @@ $childModel - $this->viewModelHelper + viewModelHelper]]> ViewModel @@ -1417,13 +1320,13 @@ $childModel - $this->viewModelHelper + viewModelHelper]]> - $this->getView() + getView()]]> - $model = $this->getCurrent() + getCurrent()]]> getChildren @@ -1431,7 +1334,7 @@ render - $this->viewModelHelper + viewModelHelper]]> @@ -1464,8 +1367,8 @@ string - $this->host - $this->scheme + host]]> + scheme]]> $_SERVER['REQUEST_URI'] @@ -1477,11 +1380,6 @@ $_SERVER['HTTPS'] === true - - - $cName - - $config['view_helper_config']['doctype'] @@ -1494,57 +1392,14 @@ $config - - - FlashMessenger - FlashMessenger - new FlashMessenger() - - - FlashMessengerFactory - - - $configHelper['message_close_string'] - $configHelper['message_open_format'] - $configHelper['message_separator_string'] - $flashMessenger - - - $configHelper['message_close_string'] - $configHelper['message_open_format'] - $configHelper['message_separator_string'] - $config['view_helper_config'] - $config['view_helper_config']['flashmessenger'] - - - $config - $configHelper - $controllerPluginManager - $flashMessenger - - - get - - - $container - - - $requestedName - - - - $this - $this - $this - (bool) $enabled - 3 === func_num_args() && is_bool($options) + is_array($params) is_bool($options) @@ -1565,10 +1420,10 @@ ! $events - $container->get('EventManager') - $container->get('MvcTranslator') - $container->get('Translator') - $container->get(TranslatorInterface::class) + get('EventManager')]]> + get('MvcTranslator')]]> + get('Translator')]]> + get(TranslatorInterface::class)]]> $container @@ -1591,8 +1446,8 @@ parent::get($name, $options) - $this->initializers - $this->initializers + initializers]]> + initializers]]> getServiceLocator @@ -1618,28 +1473,17 @@ clearVariables - - - int - - - $this->options['errorLevel'] - - - $captureTo - - - $this->type - $this->type + type]]> + type]]> false|string - $this->type - $this->type + type]]> + type]]> $variables @@ -1648,13 +1492,16 @@ $feed - $this->feed instanceof Feed + feed instanceof Feed]]> $captureTo + + getCode()]]> + @@ -1689,7 +1536,7 @@ getChildrenByCaptureTo - $child->getChildrenByCaptureTo($capture) + getChildrenByCaptureTo($capture)]]> $children @@ -1698,9 +1545,6 @@ $variables[$name] - - $variables - (bool) $append (bool) $terminate @@ -1715,29 +1559,6 @@ is_object($variables) - - - $values - - - $child - - - $child - $setting - $value - - - $setting - $this->getFilterChain()->filter($values['result']) - - - $model - - - $values - - $options['feed_type'] @@ -1753,9 +1574,6 @@ - - void - $jsonpCallback @@ -1782,6 +1600,9 @@ $children $values + + getCode()]]> + (bool) $mergeUnnamedChildren (string) $callback @@ -1791,7 +1612,7 @@ ! is_object($nameOrModel) - null !== $this->jsonpCallback + jsonpCallback]]> @@ -1804,9 +1625,9 @@ $__vars - $this->__template - $this->__template - array_pop($this->__varsCache) + __template]]> + __template]]> + __varsCache)]]> $vars[$name] @@ -1816,14 +1637,14 @@ $vars[$name] - $this->__vars[$key] - $this->__vars[$key] + __vars[$key]]]> + __vars[$key]]]> $includeReturn $setting - $this->__template - $this->__vars + __template]]> + __vars]]> $value $value $variablesAsArray[$key] @@ -1834,7 +1655,7 @@ $vars[$name] - clone $this->vars() + vars()]]> string @@ -1848,29 +1669,29 @@ $setting - $this->__filterChain->filter($this->__content) - $this->__templateResolver->resolve($name, $this) + __filterChain->filter($this->__content)]]> + __templateResolver->resolve($name, $this)]]> - $this->__templateResolver + __templateResolver]]> $variables - $this->__file + __file]]> $values - $this->resolver($this->__template) + resolver($this->__template)]]> - $this->__vars[$key] - $this->__vars[$key] + __vars[$key]]]> + __vars[$key]]]> - $this->__vars - $this->__vars + __vars]]> + __vars]]> resolve @@ -1881,7 +1702,7 @@ is_object($variables) - include $this->__file + __file]]> @@ -1891,9 +1712,9 @@ $resolver $resource - $this->lastLookupFailure - $this->lastLookupFailure - $this->lastSuccessfulResolver + lastLookupFailure]]> + lastLookupFailure]]> + lastSuccessfulResolver]]> false|string @@ -1921,8 +1742,8 @@ - ! is_array($map) && ! $map instanceof Traversable - ! is_array($map) && ! $map instanceof Traversable + + is_string($nameOrMap) @@ -1932,7 +1753,7 @@ false|string - $this->map[$name] + map[$name]]]> @@ -1947,18 +1768,16 @@ $value $value $value - $value - $this->lastLookupFailure - $this->lastLookupFailure + lastLookupFailure]]> + lastLookupFailure]]> $value - $this->paths + paths]]> - (bool) $flag (bool) $flag (string) $defaultSuffix @@ -2014,34 +1833,6 @@ plugin - - - $data - $stat - - - $mode - $offset - $opened_path - $options - $whence - - - $this->pos - $this->pos - $this->pos - - - $offset - $offset - $offset - - - break; - break; - break; - - ArrayIterator::class @@ -2126,7 +1917,7 @@ - (string) $this->helper->toString() + helper->toString()]]> @@ -2143,15 +1934,15 @@ $vars - $vars->varName1 - $vars->varName1 - $vars->varName2 - $vars->varName2 - $vars->varName3 - $vars->varName3 - $vars->varName4 - $vars->varName4 - $vars->varName5 + varName1]]> + varName1]]> + varName2]]> + varName2]]> + varName3]]> + varName3]]> + varName4]]> + varName4]]> + varName5]]> addPath @@ -2200,61 +1991,6 @@ $test - - - $plugin - $plugin - $this->mvcPluginClass - - - FlashMessenger - new FlashMessenger() - new FlashMessenger() - new FlashMessenger() - new FlashMessenger() - new FlashMessenger() - new FlashMessenger() - - - $displayInfo - $displayInfo - $displayInfo - $displayInfo - $helper - $helper - $helper - $helper - $helperPluginManager - $helperPluginManager - $helperPluginManager - $helperPluginManager - - - get - get - get - get - render - render - renderCurrent - renderCurrent - - - hasCurrentErrorMessages - hasCurrentInfoMessages - hasCurrentMessages - hasCurrentSuccessMessages - hasErrorMessages - hasInfoMessages - hasMessages - hasSuccessMessages - hasWarningMessages - render - render - renderCurrent - renderCurrent - - $value @@ -2327,17 +2063,17 @@ $attributeEscaper('/foo/bar') - $item->conditionalStylesheet - $item->conditionalStylesheet - $item->conditionalStylesheet - $item->conditionalStylesheet - $item->conditionalStylesheet - $item->media - $link->href - $link->href - $value->href - $value->href - $value->href + conditionalStylesheet]]> + conditionalStylesheet]]> + conditionalStylesheet]]> + conditionalStylesheet]]> + conditionalStylesheet]]> + media]]> + href]]> + href]]> + href]]> + href]]> + href]]> appendNext @@ -2377,9 +2113,9 @@ $item $item $item - $item->type - $item->type - $item->type + type]]> + type]]> + type]]> $modifiers $modifiers $value @@ -2418,22 +2154,22 @@ $attributeEscaper('foo bar') - $item->content - $item->content - $item->content - $item->content - $item->content - $item->name - $item->name - $item->type - $item->type - $item->type - $item->type - $item->type - $item->{$item->type} - $item->{$item->type} - $item->{$item->type} - $value->modifiers + content]]> + content]]> + content]]> + content]]> + content]]> + name]]> + name]]> + type]]> + type]]> + type]]> + type]]> + type]]> + {$item->type}]]> + {$item->type}]]> + {$item->type}]]> + modifiers]]> getArrayCopy @@ -2463,7 +2199,7 @@ $item $item $item - $item->source + source]]> $values $values $values @@ -2473,20 +2209,20 @@ $values - $first->attributes['src'] + attributes['src']]]> $items[$i] $values[$i] $values[$i] $values[$i] - $values[$i]->attributes['src'] + attributes['src']]]> $values[0] $values[0] $values[0] - $values[0]->attributes['src'] + attributes['src']]]> $values[5] $values[5] $values[5] - $values[5]->attributes['src'] + attributes['src']]]> $first @@ -2500,25 +2236,25 @@ $values - Generator<string, array<int, string> + ]]> - $first->attributes - $first->source - $first->type - $item->attributes - $item->source - $item->source - $item->source - $values[$i]->attributes - $values[$i]->source - $values[$i]->type - $values[0]->attributes - $values[0]->source - $values[0]->type - $values[5]->attributes - $values[5]->source - $values[5]->type + attributes]]> + source]]> + type]]> + attributes]]> + source]]> + source]]> + source]]> + attributes]]> + source]]> + type]]> + attributes]]> + source]]> + type]]> + attributes]]> + source]]> + type]]> getArrayCopy @@ -2533,8 +2269,8 @@ - $item->content - $item->content + content]]> + content]]> $value $values $values @@ -2544,9 +2280,9 @@ $values $values $values - $values[0]->content - $values[1]->content - $values[2]->content + content]]> + content]]> + content]]> $values[$i] @@ -2565,12 +2301,12 @@ $values - $item->content - $item->content - $value->attributes - $values[0]->content - $values[1]->content - $values[2]->content + content]]> + content]]> + attributes]]> + content]]> + content]]> + content]]> bogusMethod @@ -2594,11 +2330,6 @@ renderTitle - - - HtmlFlash - - $escape($value) @@ -2610,7 +2341,7 @@ $acl $acl - $this->serviceManager->get('Navigation') + serviceManager->get('Navigation')]]> $acl @@ -2622,7 +2353,7 @@ $_helper - $this->_helper + _helper]]> @@ -2824,9 +2555,9 @@ - function (int $code, string $message) { - $this->errorHandlerMessage = $message; - } + errorHandlerMessage = $message; + }]]> $acl['acl'] @@ -2847,13 +2578,13 @@ $_helper - $this->errorHandlerMessage + errorHandlerMessage]]> - new Page\Uri([ - 'resource' => 'unknownresource', - 'privilege' => 'someprivilege', - ], false) + 'unknownresource', + 'privilege' => 'someprivilege', + ], false)]]> PsrContainerDecorator @@ -2880,20 +2611,20 @@ plugin - $nav = clone $this->nav2; - $nav->addPage(['label' => 'Invalid', 'uri' => 'http://w.']); - static::fail('A Laminas\View\Exception\InvalidArgumentException was not thrown on invalid <loc />'); - try { - $this->_helper->render($nav); + nav2;]]> + addPage(['label' => 'Invalid', 'uri' => 'http://w.']);]]> + ');]]> + _helper->render($nav); } catch (View\Exception\ExceptionInterface $e) { $expected = sprintf( 'Encountered an invalid URL for Sitemap XML: "%s"', 'http://w.' ); - $actual = $e->getMessage(); + $actual = $e->getMessage(); static::assertEquals($expected, $actual); return; - } + }]]> @@ -2942,10 +2673,10 @@ $value - $item->message - $item->message - $item->objectKey - $item->objectKey + message]]> + message]]> + objectKey]]> + objectKey]]> $value $value @@ -3054,8 +2785,8 @@ addPath - $item->message - $item->message + message]]> + message]]> $data @@ -3082,11 +2813,11 @@ $value - $view->vars() + vars()]]> - $model->getVariables() - $model->getVariables() + getVariables()]]> + getVariables()]]> $return @@ -3131,7 +2862,7 @@ - $container->data + data]]> @@ -3142,7 +2873,7 @@ - $this->translations + translations]]> @@ -3165,6 +2896,9 @@ $value + + AllowDynamicProperties + @@ -3194,7 +2928,7 @@ $urlHelper('test') - $urlHelper('test', [], ['force_canonical' => true]) + true])]]> bootstrap @@ -3220,7 +2954,6 @@ $target - $target $alias @@ -3228,7 +2961,7 @@ $target - Generator<mixed, array{0: mixed, 1: mixed}, mixed, void> + ]]> @@ -3253,32 +2986,32 @@ new stdClass() - [ + 'bar'], 'baz', 'bar'], + [['foo' => 'bar'], null, 'bar'], + [new ArrayObject(['foo' => 'bar']), 'baz', 'bar'], + [new ArrayObject(['foo' => 'bar']), null, 'bar'], // if it is null always get null value - [['foo' => null], null, null], - [['foo' => null], 'baz', null], - [new ArrayObject(['foo' => null]), null, null], - [new ArrayObject(['foo' => null]), 'baz', null], + [['foo' => null], null, null], + [['foo' => null], 'baz', null], + [new ArrayObject(['foo' => null]), null, null], + [new ArrayObject(['foo' => null]), 'baz', null], // when it is not set always get default value [[], 'baz', 'baz'], [new ArrayObject(), 'baz', 'baz'], - ] + ]]]> - array<array-key, array{ - * 0: array<string, null|string>|ArrayObject<string, null|string>, + |ArrayObject, * 1: null|string, * 2: null|string - * }> + * }>]]> $variables['foo'] @@ -3302,7 +3035,7 @@ getArrayCopy - $this->renderer->vars()->foo + renderer->vars()->foo]]> $vars['foo'] @@ -3354,12 +3087,12 @@ - $headers->get('content-type')->getFieldValue() - $headers->get('content-type')->getFieldValue() - $headers->get('content-type')->getFieldValue() - $headers->get('content-type')->getFieldValue() - $headers->get('content-type')->getFieldValue() - $headers->get('content-type')->getFieldValue() + get('content-type')->getFieldValue()]]> + get('content-type')->getFieldValue()]]> + get('content-type')->getFieldValue()]]> + get('content-type')->getFieldValue()]]> + get('content-type')->getFieldValue()]]> + get('content-type')->getFieldValue()]]> $content @@ -3433,8 +3166,8 @@ $e - $result->content - $this->result->content + content]]> + result->content]]> $result[] From 3c2426ae91f43a5793b6916e7caf69c0667ee395 Mon Sep 17 00:00:00 2001 From: George Steel Date: Tue, 30 May 2023 13:58:22 +0100 Subject: [PATCH 32/58] Refresh lock and baseline post merge-up Signed-off-by: George Steel --- composer.lock | 340 +++++++++++++++++++++---------------------- psalm-baseline.xml | 350 ++++++++++++++++++++++++++------------------- 2 files changed, 376 insertions(+), 314 deletions(-) diff --git a/composer.lock b/composer.lock index a2579e6b1..5c2c647ee 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "1ba005afd2649475e4f5729e6c7d7e87", + "content-hash": "9e4b0916dfeafce145bdc10f7d156d58", "packages": [ { "name": "laminas/laminas-escaper", @@ -199,26 +199,26 @@ }, { "name": "laminas/laminas-servicemanager", - "version": "3.20.0", + "version": "3.21.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-servicemanager.git", - "reference": "bc2c2cbe2dd90db8b9d16b0618f542692b76ab59" + "reference": "625f2aa3bc6dd02688b2da5155b3a69870812bda" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-servicemanager/zipball/bc2c2cbe2dd90db8b9d16b0618f542692b76ab59", - "reference": "bc2c2cbe2dd90db8b9d16b0618f542692b76ab59", + "url": "https://api.github.com/repos/laminas/laminas-servicemanager/zipball/625f2aa3bc6dd02688b2da5155b3a69870812bda", + "reference": "625f2aa3bc6dd02688b2da5155b3a69870812bda", "shasum": "" }, "require": { - "laminas/laminas-stdlib": "^3.2.1", - "php": "~8.0.0 || ~8.1.0 || ~8.2.0", + "laminas/laminas-stdlib": "^3.17", + "php": "~8.1.0 || ~8.2.0", "psr/container": "^1.0" }, "conflict": { "ext-psr": "*", - "laminas/laminas-code": "<3.3.1", + "laminas/laminas-code": "<4.10.0", "zendframework/zend-code": "<3.3.1", "zendframework/zend-servicemanager": "*" }, @@ -230,18 +230,19 @@ }, "require-dev": { "composer/package-versions-deprecated": "^1.11.99.5", - "laminas/laminas-coding-standard": "~2.4.0", + "friendsofphp/proxy-manager-lts": "^1.0.14", + "laminas/laminas-code": "^4.10.0", + "laminas/laminas-coding-standard": "~2.5.0", "laminas/laminas-container-config-test": "^0.8", "laminas/laminas-dependency-plugin": "^2.2", - "mikey179/vfsstream": "^1.6.11@alpha", - "ocramius/proxy-manager": "^2.14.1", - "phpbench/phpbench": "^1.2.7", - "phpunit/phpunit": "^9.5.26", - "psalm/plugin-phpunit": "^0.18.0", - "vimeo/psalm": "^5.0.0" + "mikey179/vfsstream": "^1.6.11", + "phpbench/phpbench": "^1.2.9", + "phpunit/phpunit": "^10.0.17", + "psalm/plugin-phpunit": "^0.18.4", + "vimeo/psalm": "^5.8.0" }, "suggest": { - "ocramius/proxy-manager": "ProxyManager ^2.1.1 to handle lazy initialization of services" + "friendsofphp/proxy-manager-lts": "ProxyManager ^2.1.1 to handle lazy initialization of services" }, "bin": [ "bin/generate-deps-for-config-factory", @@ -285,34 +286,34 @@ "type": "community_bridge" } ], - "time": "2022-12-01T17:03:38+00:00" + "time": "2023-05-14T12:24:54+00:00" }, { "name": "laminas/laminas-stdlib", - "version": "3.16.1", + "version": "3.17.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-stdlib.git", - "reference": "f4f773641807c7ccee59b758bfe4ac4ba33ecb17" + "reference": "dd35c868075bad80b6718959740913e178eb4274" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-stdlib/zipball/f4f773641807c7ccee59b758bfe4ac4ba33ecb17", - "reference": "f4f773641807c7ccee59b758bfe4ac4ba33ecb17", + "url": "https://api.github.com/repos/laminas/laminas-stdlib/zipball/dd35c868075bad80b6718959740913e178eb4274", + "reference": "dd35c868075bad80b6718959740913e178eb4274", "shasum": "" }, "require": { - "php": "~8.0.0 || ~8.1.0 || ~8.2.0" + "php": "~8.1.0 || ~8.2.0" }, "conflict": { "zendframework/zend-stdlib": "*" }, "require-dev": { - "laminas/laminas-coding-standard": "^2.4.0", - "phpbench/phpbench": "^1.2.7", - "phpunit/phpunit": "^9.5.26", - "psalm/plugin-phpunit": "^0.18.0", - "vimeo/psalm": "^5.0.0" + "laminas/laminas-coding-standard": "^2.5", + "phpbench/phpbench": "^1.2.9", + "phpunit/phpunit": "^10.0.16", + "psalm/plugin-phpunit": "^0.18.4", + "vimeo/psalm": "^5.8" }, "type": "library", "autoload": { @@ -344,7 +345,7 @@ "type": "community_bridge" } ], - "time": "2022-12-03T18:48:01+00:00" + "time": "2023-03-20T13:51:37+00:00" }, { "name": "psr/container", @@ -1016,30 +1017,30 @@ }, { "name": "doctrine/instantiator", - "version": "1.5.0", + "version": "2.0.0", "source": { "type": "git", "url": "https://github.com/doctrine/instantiator.git", - "reference": "0a0fa9780f5d4e507415a065172d26a98d02047b" + "reference": "c6222283fa3f4ac679f8b9ced9a4e23f163e80d0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/instantiator/zipball/0a0fa9780f5d4e507415a065172d26a98d02047b", - "reference": "0a0fa9780f5d4e507415a065172d26a98d02047b", + "url": "https://api.github.com/repos/doctrine/instantiator/zipball/c6222283fa3f4ac679f8b9ced9a4e23f163e80d0", + "reference": "c6222283fa3f4ac679f8b9ced9a4e23f163e80d0", "shasum": "" }, "require": { - "php": "^7.1 || ^8.0" + "php": "^8.1" }, "require-dev": { - "doctrine/coding-standard": "^9 || ^11", + "doctrine/coding-standard": "^11", "ext-pdo": "*", "ext-phar": "*", - "phpbench/phpbench": "^0.16 || ^1", - "phpstan/phpstan": "^1.4", - "phpstan/phpstan-phpunit": "^1", - "phpunit/phpunit": "^7.5 || ^8.5 || ^9.5", - "vimeo/psalm": "^4.30 || ^5.4" + "phpbench/phpbench": "^1.2", + "phpstan/phpstan": "^1.9.4", + "phpstan/phpstan-phpunit": "^1.3", + "phpunit/phpunit": "^9.5.27", + "vimeo/psalm": "^5.4" }, "type": "library", "autoload": { @@ -1066,7 +1067,7 @@ ], "support": { "issues": "https://github.com/doctrine/instantiator/issues", - "source": "https://github.com/doctrine/instantiator/tree/1.5.0" + "source": "https://github.com/doctrine/instantiator/tree/2.0.0" }, "funding": [ { @@ -1082,7 +1083,7 @@ "type": "tidelift" } ], - "time": "2022-12-30T00:15:36+00:00" + "time": "2022-12-30T00:23:10+00:00" }, { "name": "felixfbecker/advanced-json-rpc", @@ -1528,23 +1529,23 @@ }, { "name": "laminas/laminas-filter", - "version": "2.31.0", + "version": "2.32.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-filter.git", - "reference": "548a6597d357b0b0b139cc7bffea4dfbc50eb5a8" + "reference": "2b7e6b2b26a92412c38336ee3089251164edf141" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-filter/zipball/548a6597d357b0b0b139cc7bffea4dfbc50eb5a8", - "reference": "548a6597d357b0b0b139cc7bffea4dfbc50eb5a8", + "url": "https://api.github.com/repos/laminas/laminas-filter/zipball/2b7e6b2b26a92412c38336ee3089251164edf141", + "reference": "2b7e6b2b26a92412c38336ee3089251164edf141", "shasum": "" }, "require": { "ext-mbstring": "*", - "laminas/laminas-servicemanager": "^3.14.0", + "laminas/laminas-servicemanager": "^3.21.0", "laminas/laminas-stdlib": "^3.13.0", - "php": "~8.0.0 || ~8.1.0 || ~8.2.0" + "php": "~8.1.0 || ~8.2.0" }, "conflict": { "laminas/laminas-validator": "<2.10.1", @@ -1552,13 +1553,13 @@ }, "require-dev": { "laminas/laminas-coding-standard": "~2.5.0", - "laminas/laminas-crypt": "^3.9", + "laminas/laminas-crypt": "^3.10", "laminas/laminas-uri": "^2.10", "pear/archive_tar": "^1.4.14", - "phpunit/phpunit": "^9.5.27", + "phpunit/phpunit": "^10.1.3", "psalm/plugin-phpunit": "^0.18.4", - "psr/http-factory": "^1.0.1", - "vimeo/psalm": "^5.3" + "psr/http-factory": "^1.0.2", + "vimeo/psalm": "^5.11" }, "suggest": { "laminas/laminas-crypt": "Laminas\\Crypt component, for encryption filters", @@ -1602,7 +1603,7 @@ "type": "community_bridge" } ], - "time": "2023-01-12T06:17:48+00:00" + "time": "2023-05-16T23:25:05+00:00" }, { "name": "laminas/laminas-http", @@ -1671,42 +1672,41 @@ }, { "name": "laminas/laminas-i18n", - "version": "2.22.1", + "version": "2.23.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-i18n.git", - "reference": "075bec49f777698c6fc229eecefbe7a2364cd18e" + "reference": "bb844a1141bb6e65d8889f5a08383f761a8270b2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-i18n/zipball/075bec49f777698c6fc229eecefbe7a2364cd18e", - "reference": "075bec49f777698c6fc229eecefbe7a2364cd18e", + "url": "https://api.github.com/repos/laminas/laminas-i18n/zipball/bb844a1141bb6e65d8889f5a08383f761a8270b2", + "reference": "bb844a1141bb6e65d8889f5a08383f761a8270b2", "shasum": "" }, "require": { "ext-intl": "*", - "laminas/laminas-servicemanager": "^3.14.0", - "laminas/laminas-stdlib": "^2.7 || ^3.0", - "php": "~8.0.0 || ~8.1.0 || ~8.2.0" + "laminas/laminas-servicemanager": "^3.21.0", + "laminas/laminas-stdlib": "^3.0", + "php": "~8.1.0 || ~8.2.0" }, "conflict": { "laminas/laminas-view": "<2.20.0", - "phpspec/prophecy": "<1.9.0", "zendframework/zend-i18n": "*" }, "require-dev": { - "laminas/laminas-cache": "^3.8", + "laminas/laminas-cache": "^3.10.1", "laminas/laminas-cache-storage-adapter-memory": "^2.2.0", - "laminas/laminas-cache-storage-deprecated-factory": "^1.0.1", + "laminas/laminas-cache-storage-deprecated-factory": "^1.1", "laminas/laminas-coding-standard": "~2.5.0", "laminas/laminas-config": "^3.8.0", - "laminas/laminas-eventmanager": "^3.7", - "laminas/laminas-filter": "^2.28.1", - "laminas/laminas-validator": "^2.28", - "laminas/laminas-view": "^2.25", - "phpunit/phpunit": "^9.5.26", - "psalm/plugin-phpunit": "^0.18.3", - "vimeo/psalm": "^5.0.0" + "laminas/laminas-eventmanager": "^3.10", + "laminas/laminas-filter": "^2.31", + "laminas/laminas-validator": "^2.30.1", + "laminas/laminas-view": "^2.27", + "phpunit/phpunit": "^10.1.3", + "psalm/plugin-phpunit": "^0.18.4", + "vimeo/psalm": "^5.11" }, "suggest": { "laminas/laminas-cache": "You should install this package to cache the translations", @@ -1753,7 +1753,7 @@ "type": "community_bridge" } ], - "time": "2023-03-31T12:31:38+00:00" + "time": "2023-05-16T23:22:24+00:00" }, { "name": "laminas/laminas-loader", @@ -2204,20 +2204,20 @@ }, { "name": "laminas/laminas-permissions-acl", - "version": "2.14.0", + "version": "2.15.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-permissions-acl.git", - "reference": "86cecb540cf8f2e088d70d8acef1fc9203ed5023" + "reference": "ea9f6643a624b3e847f7d637eb828498654f492e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-permissions-acl/zipball/86cecb540cf8f2e088d70d8acef1fc9203ed5023", - "reference": "86cecb540cf8f2e088d70d8acef1fc9203ed5023", + "url": "https://api.github.com/repos/laminas/laminas-permissions-acl/zipball/ea9f6643a624b3e847f7d637eb828498654f492e", + "reference": "ea9f6643a624b3e847f7d637eb828498654f492e", "shasum": "" }, "require": { - "php": "~8.0.0 || ~8.1.0 || ~8.2.0" + "php": "~8.1.0 || ~8.2.0" }, "conflict": { "laminas/laminas-servicemanager": "<3.0", @@ -2225,11 +2225,11 @@ }, "require-dev": { "laminas/laminas-coding-standard": "~2.5.0", - "laminas/laminas-servicemanager": "^3.19", - "phpbench/phpbench": "^1.2", - "phpunit/phpunit": "^9.5.26", - "psalm/plugin-phpunit": "^0.18.0", - "vimeo/psalm": "^5.0" + "laminas/laminas-servicemanager": "^3.21", + "phpbench/phpbench": "^1.2.10", + "phpunit/phpunit": "^10.1.3", + "psalm/plugin-phpunit": "^0.18.4", + "vimeo/psalm": "^5.12" }, "suggest": { "laminas/laminas-servicemanager": "To support Laminas\\Permissions\\Acl\\Assertion\\AssertionManager plugin manager usage" @@ -2264,7 +2264,7 @@ "type": "community_bridge" } ], - "time": "2023-02-01T16:19:54+00:00" + "time": "2023-05-29T19:28:02+00:00" }, { "name": "laminas/laminas-router", @@ -2397,40 +2397,40 @@ }, { "name": "laminas/laminas-validator", - "version": "2.30.1", + "version": "2.31.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-validator.git", - "reference": "b7d217b5e4951955fda9a3a5ada91b717b5c8d5c" + "reference": "7dc274aa5afd5e23be0dbea13363e3d66ba5808b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-validator/zipball/b7d217b5e4951955fda9a3a5ada91b717b5c8d5c", - "reference": "b7d217b5e4951955fda9a3a5ada91b717b5c8d5c", + "url": "https://api.github.com/repos/laminas/laminas-validator/zipball/7dc274aa5afd5e23be0dbea13363e3d66ba5808b", + "reference": "7dc274aa5afd5e23be0dbea13363e3d66ba5808b", "shasum": "" }, "require": { - "laminas/laminas-servicemanager": "^3.12.0", + "laminas/laminas-servicemanager": "^3.21.0", "laminas/laminas-stdlib": "^3.13", - "php": "~8.0.0 || ~8.1.0 || ~8.2.0", - "psr/http-message": "^1.0.1" + "php": "~8.1.0 || ~8.2.0", + "psr/http-message": "^1.0.1 || ^2.0.0" }, "conflict": { "zendframework/zend-validator": "*" }, "require-dev": { - "laminas/laminas-coding-standard": "^2.4.0", - "laminas/laminas-db": "^2.16", - "laminas/laminas-filter": "^2.28.1", + "laminas/laminas-coding-standard": "^2.5", + "laminas/laminas-db": "^2.18", + "laminas/laminas-filter": "^2.32", "laminas/laminas-http": "^2.18", - "laminas/laminas-i18n": "^2.19", - "laminas/laminas-session": "^2.15", + "laminas/laminas-i18n": "^2.23", + "laminas/laminas-session": "^2.16", "laminas/laminas-uri": "^2.10.0", - "phpunit/phpunit": "^9.5.26", - "psalm/plugin-phpunit": "^0.18.3", - "psr/http-client": "^1.0.1", - "psr/http-factory": "^1.0.1", - "vimeo/psalm": "^5.0" + "phpunit/phpunit": "^10.1.3", + "psalm/plugin-phpunit": "^0.18.4", + "psr/http-client": "^1.0.2", + "psr/http-factory": "^1.0.2", + "vimeo/psalm": "^5.11" }, "suggest": { "laminas/laminas-db": "Laminas\\Db component, required by the (No)RecordExists validator", @@ -2478,7 +2478,7 @@ "type": "community_bridge" } ], - "time": "2023-01-30T22:41:19+00:00" + "time": "2023-05-19T09:42:26+00:00" }, { "name": "myclabs/deep-copy", @@ -2592,16 +2592,16 @@ }, { "name": "nikic/php-parser", - "version": "v4.15.4", + "version": "v4.15.5", "source": { "type": "git", "url": "https://github.com/nikic/PHP-Parser.git", - "reference": "6bb5176bc4af8bcb7d926f88718db9b96a2d4290" + "reference": "11e2663a5bc9db5d714eedb4277ee300403b4a9e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/6bb5176bc4af8bcb7d926f88718db9b96a2d4290", - "reference": "6bb5176bc4af8bcb7d926f88718db9b96a2d4290", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/11e2663a5bc9db5d714eedb4277ee300403b4a9e", + "reference": "11e2663a5bc9db5d714eedb4277ee300403b4a9e", "shasum": "" }, "require": { @@ -2642,9 +2642,9 @@ ], "support": { "issues": "https://github.com/nikic/PHP-Parser/issues", - "source": "https://github.com/nikic/PHP-Parser/tree/v4.15.4" + "source": "https://github.com/nikic/PHP-Parser/tree/v4.15.5" }, - "time": "2023-03-05T19:49:14+00:00" + "time": "2023-05-19T20:20:00+00:00" }, { "name": "phar-io/manifest", @@ -3286,16 +3286,16 @@ }, { "name": "phpunit/phpunit", - "version": "9.6.7", + "version": "9.6.8", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "c993f0d3b0489ffc42ee2fe0bd645af1538a63b2" + "reference": "17d621b3aff84d0c8b62539e269e87d8d5baa76e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/c993f0d3b0489ffc42ee2fe0bd645af1538a63b2", - "reference": "c993f0d3b0489ffc42ee2fe0bd645af1538a63b2", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/17d621b3aff84d0c8b62539e269e87d8d5baa76e", + "reference": "17d621b3aff84d0c8b62539e269e87d8d5baa76e", "shasum": "" }, "require": { @@ -3369,7 +3369,7 @@ "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", "security": "https://github.com/sebastianbergmann/phpunit/security/policy", - "source": "https://github.com/sebastianbergmann/phpunit/tree/9.6.7" + "source": "https://github.com/sebastianbergmann/phpunit/tree/9.6.8" }, "funding": [ { @@ -3385,7 +3385,7 @@ "type": "tidelift" } ], - "time": "2023-04-14T08:58:40+00:00" + "time": "2023-05-11T05:14:45+00:00" }, { "name": "psalm/plugin-phpunit", @@ -3449,16 +3449,16 @@ }, { "name": "psr/http-message", - "version": "1.1", + "version": "2.0", "source": { "type": "git", "url": "https://github.com/php-fig/http-message.git", - "reference": "cb6ce4845ce34a8ad9e68117c10ee90a29919eba" + "reference": "402d35bcb92c70c026d1a6a9883f06b2ead23d71" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/http-message/zipball/cb6ce4845ce34a8ad9e68117c10ee90a29919eba", - "reference": "cb6ce4845ce34a8ad9e68117c10ee90a29919eba", + "url": "https://api.github.com/repos/php-fig/http-message/zipball/402d35bcb92c70c026d1a6a9883f06b2ead23d71", + "reference": "402d35bcb92c70c026d1a6a9883f06b2ead23d71", "shasum": "" }, "require": { @@ -3467,7 +3467,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-master": "1.1.x-dev" + "dev-master": "2.0.x-dev" } }, "autoload": { @@ -3482,7 +3482,7 @@ "authors": [ { "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" + "homepage": "https://www.php-fig.org/" } ], "description": "Common interface for HTTP messages", @@ -3496,9 +3496,9 @@ "response" ], "support": { - "source": "https://github.com/php-fig/http-message/tree/1.1" + "source": "https://github.com/php-fig/http-message/tree/2.0" }, - "time": "2023-04-04T09:50:52+00:00" + "time": "2023-04-04T09:54:51+00:00" }, { "name": "psr/log", @@ -3850,16 +3850,16 @@ }, { "name": "sebastian/diff", - "version": "4.0.4", + "version": "4.0.5", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/diff.git", - "reference": "3461e3fccc7cfdfc2720be910d3bd73c69be590d" + "reference": "74be17022044ebaaecfdf0c5cd504fc9cd5a7131" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/3461e3fccc7cfdfc2720be910d3bd73c69be590d", - "reference": "3461e3fccc7cfdfc2720be910d3bd73c69be590d", + "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/74be17022044ebaaecfdf0c5cd504fc9cd5a7131", + "reference": "74be17022044ebaaecfdf0c5cd504fc9cd5a7131", "shasum": "" }, "require": { @@ -3904,7 +3904,7 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/diff/issues", - "source": "https://github.com/sebastianbergmann/diff/tree/4.0.4" + "source": "https://github.com/sebastianbergmann/diff/tree/4.0.5" }, "funding": [ { @@ -3912,7 +3912,7 @@ "type": "github" } ], - "time": "2020-10-26T13:10:38+00:00" + "time": "2023-05-07T05:35:17+00:00" }, { "name": "sebastian/environment", @@ -4577,16 +4577,16 @@ }, { "name": "spatie/array-to-xml", - "version": "3.1.5", + "version": "3.1.6", "source": { "type": "git", "url": "https://github.com/spatie/array-to-xml.git", - "reference": "13f76acef5362d15c71ae1ac6350cc3df5e25e43" + "reference": "e210b98957987c755372465be105d32113f339a4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/spatie/array-to-xml/zipball/13f76acef5362d15c71ae1ac6350cc3df5e25e43", - "reference": "13f76acef5362d15c71ae1ac6350cc3df5e25e43", + "url": "https://api.github.com/repos/spatie/array-to-xml/zipball/e210b98957987c755372465be105d32113f339a4", + "reference": "e210b98957987c755372465be105d32113f339a4", "shasum": "" }, "require": { @@ -4624,7 +4624,7 @@ "xml" ], "support": { - "source": "https://github.com/spatie/array-to-xml/tree/3.1.5" + "source": "https://github.com/spatie/array-to-xml/tree/3.1.6" }, "funding": [ { @@ -4636,7 +4636,7 @@ "type": "github" } ], - "time": "2022-12-24T13:43:51+00:00" + "time": "2023-05-11T14:04:07+00:00" }, { "name": "squizlabs/php_codesniffer", @@ -4697,20 +4697,21 @@ }, { "name": "symfony/console", - "version": "v6.0.19", + "version": "v6.2.11", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "c3ebc83d031b71c39da318ca8b7a07ecc67507ed" + "reference": "5aa03db8ef0a5457c316ec580e69562d97734c77" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/c3ebc83d031b71c39da318ca8b7a07ecc67507ed", - "reference": "c3ebc83d031b71c39da318ca8b7a07ecc67507ed", + "url": "https://api.github.com/repos/symfony/console/zipball/5aa03db8ef0a5457c316ec580e69562d97734c77", + "reference": "5aa03db8ef0a5457c316ec580e69562d97734c77", "shasum": "" }, "require": { - "php": ">=8.0.2", + "php": ">=8.1", + "symfony/deprecation-contracts": "^2.1|^3", "symfony/polyfill-mbstring": "~1.0", "symfony/service-contracts": "^1.1|^2|^3", "symfony/string": "^5.4|^6.0" @@ -4767,12 +4768,12 @@ "homepage": "https://symfony.com", "keywords": [ "cli", - "command line", + "command-line", "console", "terminal" ], "support": { - "source": "https://github.com/symfony/console/tree/v6.0.19" + "source": "https://github.com/symfony/console/tree/v6.2.11" }, "funding": [ { @@ -4788,29 +4789,29 @@ "type": "tidelift" } ], - "time": "2023-01-01T08:36:10+00:00" + "time": "2023-05-26T08:16:21+00:00" }, { "name": "symfony/deprecation-contracts", - "version": "v3.0.2", + "version": "v3.2.1", "source": { "type": "git", "url": "https://github.com/symfony/deprecation-contracts.git", - "reference": "26954b3d62a6c5fd0ea8a2a00c0353a14978d05c" + "reference": "e2d1534420bd723d0ef5aec58a22c5fe60ce6f5e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/26954b3d62a6c5fd0ea8a2a00c0353a14978d05c", - "reference": "26954b3d62a6c5fd0ea8a2a00c0353a14978d05c", + "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/e2d1534420bd723d0ef5aec58a22c5fe60ce6f5e", + "reference": "e2d1534420bd723d0ef5aec58a22c5fe60ce6f5e", "shasum": "" }, "require": { - "php": ">=8.0.2" + "php": ">=8.1" }, "type": "library", "extra": { "branch-alias": { - "dev-main": "3.0-dev" + "dev-main": "3.3-dev" }, "thanks": { "name": "symfony/contracts", @@ -4839,7 +4840,7 @@ "description": "A generic function and convention to trigger deprecation notices", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/deprecation-contracts/tree/v3.0.2" + "source": "https://github.com/symfony/deprecation-contracts/tree/v3.2.1" }, "funding": [ { @@ -4855,24 +4856,24 @@ "type": "tidelift" } ], - "time": "2022-01-02T09:55:41+00:00" + "time": "2023-03-01T10:25:55+00:00" }, { "name": "symfony/filesystem", - "version": "v6.0.19", + "version": "v6.2.10", "source": { "type": "git", "url": "https://github.com/symfony/filesystem.git", - "reference": "3d49eec03fda1f0fc19b7349fbbe55ebc1004214" + "reference": "fd588debf7d1bc16a2c84b4b3b71145d9946b894" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/filesystem/zipball/3d49eec03fda1f0fc19b7349fbbe55ebc1004214", - "reference": "3d49eec03fda1f0fc19b7349fbbe55ebc1004214", + "url": "https://api.github.com/repos/symfony/filesystem/zipball/fd588debf7d1bc16a2c84b4b3b71145d9946b894", + "reference": "fd588debf7d1bc16a2c84b4b3b71145d9946b894", "shasum": "" }, "require": { - "php": ">=8.0.2", + "php": ">=8.1", "symfony/polyfill-ctype": "~1.8", "symfony/polyfill-mbstring": "~1.8" }, @@ -4902,7 +4903,7 @@ "description": "Provides basic utilities for the filesystem", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/filesystem/tree/v6.0.19" + "source": "https://github.com/symfony/filesystem/tree/v6.2.10" }, "funding": [ { @@ -4918,7 +4919,7 @@ "type": "tidelift" } ], - "time": "2023-01-20T17:44:14+00:00" + "time": "2023-04-18T13:46:08+00:00" }, { "name": "symfony/polyfill-ctype", @@ -5335,20 +5336,20 @@ }, { "name": "symfony/string", - "version": "v6.0.19", + "version": "v6.2.8", "source": { "type": "git", "url": "https://github.com/symfony/string.git", - "reference": "d9e72497367c23e08bf94176d2be45b00a9d232a" + "reference": "193e83bbd6617d6b2151c37fff10fa7168ebddef" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/string/zipball/d9e72497367c23e08bf94176d2be45b00a9d232a", - "reference": "d9e72497367c23e08bf94176d2be45b00a9d232a", + "url": "https://api.github.com/repos/symfony/string/zipball/193e83bbd6617d6b2151c37fff10fa7168ebddef", + "reference": "193e83bbd6617d6b2151c37fff10fa7168ebddef", "shasum": "" }, "require": { - "php": ">=8.0.2", + "php": ">=8.1", "symfony/polyfill-ctype": "~1.8", "symfony/polyfill-intl-grapheme": "~1.0", "symfony/polyfill-intl-normalizer": "~1.0", @@ -5360,6 +5361,7 @@ "require-dev": { "symfony/error-handler": "^5.4|^6.0", "symfony/http-client": "^5.4|^6.0", + "symfony/intl": "^6.2", "symfony/translation-contracts": "^2.0|^3.0", "symfony/var-exporter": "^5.4|^6.0" }, @@ -5400,7 +5402,7 @@ "utf8" ], "support": { - "source": "https://github.com/symfony/string/tree/v6.0.19" + "source": "https://github.com/symfony/string/tree/v6.2.8" }, "funding": [ { @@ -5416,7 +5418,7 @@ "type": "tidelift" } ], - "time": "2023-01-01T08:36:10+00:00" + "time": "2023-03-20T16:06:02+00:00" }, { "name": "theseer/tokenizer", @@ -5470,16 +5472,16 @@ }, { "name": "vimeo/psalm", - "version": "5.9.0", + "version": "5.12.0", "source": { "type": "git", "url": "https://github.com/vimeo/psalm.git", - "reference": "8b9ad1eb9e8b7d3101f949291da2b9f7767cd163" + "reference": "f90118cdeacd0088e7215e64c0c99ceca819e176" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/vimeo/psalm/zipball/8b9ad1eb9e8b7d3101f949291da2b9f7767cd163", - "reference": "8b9ad1eb9e8b7d3101f949291da2b9f7767cd163", + "url": "https://api.github.com/repos/vimeo/psalm/zipball/f90118cdeacd0088e7215e64c0c99ceca819e176", + "reference": "f90118cdeacd0088e7215e64c0c99ceca819e176", "shasum": "" }, "require": { @@ -5570,9 +5572,9 @@ ], "support": { "issues": "https://github.com/vimeo/psalm/issues", - "source": "https://github.com/vimeo/psalm/tree/5.9.0" + "source": "https://github.com/vimeo/psalm/tree/5.12.0" }, - "time": "2023-03-29T21:38:21+00:00" + "time": "2023-05-22T21:19:03+00:00" }, { "name": "webimpress/coding-standard", @@ -5753,14 +5755,14 @@ "prefer-stable": false, "prefer-lowest": false, "platform": { - "php": "~8.0.0 || ~8.1.0 || ~8.2.0", + "php": "~8.1.0 || ~8.2.0", "ext-dom": "*", "ext-filter": "*", "ext-json": "*" }, "platform-dev": [], "platform-overrides": { - "php": "8.0.99" + "php": "8.1.99" }, "plugin-api-version": "2.3.0" } diff --git a/psalm-baseline.xml b/psalm-baseline.xml index 2f626aaf9..74aa7aded 100644 --- a/psalm-baseline.xml +++ b/psalm-baseline.xml @@ -1,5 +1,5 @@ - + $templatePath @@ -57,6 +57,9 @@ Cycle Cycle + + __toString + Iterator @@ -116,6 +119,9 @@ null === static::$registeredDoctypes + + __toString + registry['doctypes'][$type]]]> @@ -142,6 +148,9 @@ $flag === null + + __toString + $attributes $email @@ -186,6 +195,9 @@ (object) $attributes + + offsetSet + $args $args @@ -202,7 +214,7 @@ $value - $extras['media'] + $media @@ -237,7 +249,7 @@ rel]]> - call_user_func_array([$this, '__invoke'], func_get_args()) + $value @@ -276,6 +288,10 @@ $item + + offsetSet + offsetUnset + $args[0] $args[1] @@ -358,8 +374,11 @@ - ['type'] + + + offsetSet + $content $content @@ -376,7 +395,7 @@ $value - $attrs['src'] + $content $indent $index @@ -441,6 +460,9 @@ + + offsetSet + $content $enc @@ -451,10 +473,9 @@ attributes['conditional']]]> $key $value - $value - $attributes['media'] + attributes['conditional']]]> @@ -648,6 +669,9 @@ Navigation\Exception\ExceptionInterface + + __toString + $container $container @@ -695,7 +719,7 @@ $events - strrpos($prefix, '\\') + getTitle()]]> @@ -708,7 +732,6 @@ attach getParent plugin - translate (bool) $renderInvisible @@ -732,7 +755,7 @@ setSharedManager - return ''; + @@ -754,19 +777,19 @@ $active getLabel()]]> getTextDomain()]]> - $model['pages'] + $partial[0] - $model['pages'][] - $model['pages'][] + + $active $active $active $label - $model['pages'][] + $parent @@ -879,9 +902,9 @@ isAllowed - $params['acl'] - $params['page'] - $params['role'] + + + @@ -900,22 +923,22 @@ $partial - $options['addClassToListItem'] - $options['addClassToListItem'] - $options['escapeLabels'] - $options['escapeLabels'] - $options['indent'] - $options['indent'] - $options['indent'] - $options['liActiveClass'] - $options['liActiveClass'] - $options['maxDepth'] - $options['maxDepth'] - $options['minDepth'] - $options['minDepth'] - $options['onlyActiveBranch'] - $options['ulClass'] - $options['ulClass'] + + + + + + + + + + + + + + + + $page $page getTextDomain()]]> @@ -927,8 +950,8 @@ $liClasses - $active['page'] - $active['page'] + + $foundDepth $foundPage $isActive @@ -950,12 +973,12 @@ isActive - $active['depth'] + $escaper($label) $escaper($ulClass) $escaper($ulClass) - $escaper(implode(' ', $liClasses)) - $escaper(implode(' ', $liClasses)) + + $foundDepth @@ -1194,6 +1217,9 @@ self + + __toString + AbstractContainer @@ -1237,6 +1263,9 @@ container]]> + + __toString + ArrayAccess IteratorAggregate @@ -1359,7 +1388,7 @@ - $_SERVER['SERVER_PORT'] + $port @@ -1371,22 +1400,22 @@ scheme]]> - $_SERVER['REQUEST_URI'] + (bool) $useProxy - $_SERVER['HTTPS'] === true + - $config['view_helper_config']['doctype'] + - $config['view_helper_config'] - $config['view_helper_config']['doctype'] + + $config @@ -1404,21 +1433,27 @@ is_bool($options) - $options['name'] + $reuseMatchedParams - $routeMatchParams['controller'] + $options + + null|ConfigInterface|ContainerInterface + ! $events ! $events + + get + get('EventManager')]]> get('MvcTranslator')]]> @@ -1561,7 +1596,7 @@ - $options['feed_type'] + $resolver @@ -1834,9 +1869,6 @@ - - ArrayIterator::class - Variables @@ -1908,7 +1940,7 @@ $value - $params['result'] + $name @@ -2003,19 +2035,19 @@ - 'foo' - 'foo' + + - $attributeEscaper('/styles.css') - $attributeEscaper('/styles.css') - $attributeEscaper('/styles.css') - $attributeEscaper('/styles.css') - $attributeEscaper('/test1.css') - $attributeEscaper('/test2.css') - $attributeEscaper('/test3.css') - $attributeEscaper('/test4.css') - $attributeEscaper('text/css') + + + + + + + + + $item $item $item @@ -2050,17 +2082,17 @@ iterable - $attributeEscaper($link['href']) - $attributeEscaper($link['href']) - $attributeEscaper($link['href']) - $attributeEscaper($link['rel']) - $attributeEscaper($link['rel']) - $attributeEscaper($link['title']) - $attributeEscaper($link['type']) - $attributeEscaper($link['type']) - $attributeEscaper($link['type']) - $attributeEscaper('/foo/bar') - $attributeEscaper('/foo/bar') + + + + + + + + + + + conditionalStylesheet]]> @@ -2091,16 +2123,16 @@ - 'foo' - 'foo' - 'foo' - [$this, 'handleErrors'] + + + + - $attributeEscaper('HeadMeta with Microdata') - $attributeEscaper('og:title') - $attributeEscaper('some content') - $attributeEscaper('some content') + + + + $item $item $item @@ -2130,8 +2162,8 @@ $values - $modifiers['lang'] - $modifiers['scheme'] + + $values[$i] $values[100] @@ -2150,8 +2182,8 @@ $values - $attributeEscaper('boo bah') - $attributeEscaper('foo bar') + + content]]> @@ -2191,11 +2223,11 @@ public function booleanAttributeDataProvider(): Generator - $attributeEscaper('test1.js') - $attributeEscaper('test2.js') - $attributeEscaper('test3.js') - $attributeEscaper('test4.js') - $attributeEscaper('text/javascript') + + + + + $item $item $item @@ -2334,7 +2366,7 @@ $escape($value) $escape($value) - $escape('http://www.w3.org/1999/xhtml') + @@ -2357,6 +2389,9 @@ + + getDependencyConfig())]]> + $app @@ -2372,16 +2407,16 @@ null - new GenericResource('admin_foo', 'member_foo') + - 'Navigation' - 'Navigation' + + - $acl['acl'] + $_helper @@ -2530,15 +2565,15 @@ - 'Navigation' - 'Navigation' + + - $acl['acl'] - $acl['acl'] - $acl['acl'] - $acl['acl'] - $acl['acl'] + + + + + $p @@ -2560,9 +2595,9 @@ }]]> - $acl['acl'] - $acl['acl'] - $acl['acl'] + + + $actual @@ -2589,14 +2624,20 @@ PsrContainerDecorator - - $code - + + + + [ + 'default' => [], + ], + ])]]> + - $acl['acl'] - $acl['acl'] + + setBasePath @@ -2631,7 +2672,7 @@ $all $paginator - ['partial.phtml', 'test'] + null @@ -2653,8 +2694,8 @@ $rIterator $rIterator $rIterator - 'foo' - 'foo' + + new stdClass() new stdClass() @@ -2912,6 +2953,9 @@ + + getDependencyConfig())]]> + $serviceConfig $test @@ -2927,7 +2971,7 @@ $viewHelpers - $urlHelper('test') + true])]]> @@ -2946,12 +2990,20 @@ $it $router $router - 'invalid params' + true true + + [ + 'config' => [], + ], + 'factories' => $factories, + ])]]> + $target @@ -2965,6 +3017,42 @@ + + [ + 'foo' => static fn($container) => $helper, + ], + ] + )]]> + [ + Url::class => static fn($container) => $helper, + ], + ] + )]]> + [ + 'MvcTranslator' => $translator, + ], + ])]]> + [ + 'Translator' => $translator, + ], + ])]]> + [ + 'Translator' => $translatorB, + ], + ])]]> + [ + TranslatorInterface::class => $translator, + ], + ])]]> + $container $container @@ -2985,36 +3073,8 @@ new stdClass() new stdClass() - - 'bar'], 'baz', 'bar'], - [['foo' => 'bar'], null, 'bar'], - [new ArrayObject(['foo' => 'bar']), 'baz', 'bar'], - [new ArrayObject(['foo' => 'bar']), null, 'bar'], - - // if it is null always get null value - [['foo' => null], null, null], - [['foo' => null], 'baz', null], - [new ArrayObject(['foo' => null]), null, null], - [new ArrayObject(['foo' => null]), 'baz', null], - - // when it is not set always get default value - [[], 'baz', 'baz'], - [new ArrayObject(), 'baz', 'baz'], - ]]]> - - - |ArrayObject, - * 1: null|string, - * 2: null|string - * }>]]> - - $variables['foo'] + @@ -3038,7 +3098,7 @@ renderer->vars()->foo]]> - $vars['foo'] + $errno From 63b2e56f1760942e3681bbab7273bf4fa2933499 Mon Sep 17 00:00:00 2001 From: George Steel Date: Thu, 20 Jul 2023 10:17:14 +0100 Subject: [PATCH 33/58] Exception code does not need a cast to int Signed-off-by: George Steel --- src/Model/JsonModel.php | 2 +- src/Renderer/JsonRenderer.php | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Model/JsonModel.php b/src/Model/JsonModel.php index 2d4c9b761..365a8e770 100644 --- a/src/Model/JsonModel.php +++ b/src/Model/JsonModel.php @@ -76,7 +76,7 @@ private function jsonEncode($data, int $options): string try { return json_encode($data, $options | JSON_THROW_ON_ERROR); } catch (JsonException $e) { - throw new DomainException('Failed to encode Json', (int) $e->getCode(), $e); + throw new DomainException('Failed to encode Json', $e->getCode(), $e); } } } diff --git a/src/Renderer/JsonRenderer.php b/src/Renderer/JsonRenderer.php index c296cd2bc..a55bd4767 100644 --- a/src/Renderer/JsonRenderer.php +++ b/src/Renderer/JsonRenderer.php @@ -248,7 +248,7 @@ private function jsonEncode($data): string try { return json_encode($data, JSON_THROW_ON_ERROR); } catch (JsonException $e) { - throw new Exception\DomainException('Json encoding failed', (int) $e->getCode(), $e); + throw new Exception\DomainException('Json encoding failed', $e->getCode(), $e); } } } From e422f3a1c61bbf0306d27d755ef1c59682aab4f3 Mon Sep 17 00:00:00 2001 From: George Steel Date: Thu, 20 Jul 2023 10:17:43 +0100 Subject: [PATCH 34/58] `MockObject::withConsecutive()` is not available in PHPUnit 10 Signed-off-by: George Steel --- test/Helper/Service/IdentityFactoryTest.php | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/test/Helper/Service/IdentityFactoryTest.php b/test/Helper/Service/IdentityFactoryTest.php index e8685ccb0..27c782ea0 100644 --- a/test/Helper/Service/IdentityFactoryTest.php +++ b/test/Helper/Service/IdentityFactoryTest.php @@ -27,10 +27,15 @@ public function testFactoryReturnsEmptyIdentityIfNoAuthenticationServicePresent( { $this->services->expects(self::exactly(2)) ->method('has') - ->withConsecutive( - [AuthenticationService::class], - [AuthenticationServiceInterface::class] - )->willReturn(false); + ->with(self::callback(static function (string $serviceName): bool { + self::assertTrue( + $serviceName === AuthenticationService::class + || + $serviceName === AuthenticationServiceInterface::class + ); + + return true; + }))->willReturn(false); $factory = new IdentityFactory(); From 2a97feaf432daf885e6b90ec1679cf972087ad2f Mon Sep 17 00:00:00 2001 From: George Steel Date: Thu, 20 Jul 2023 10:18:05 +0100 Subject: [PATCH 35/58] Refresh lock and baseline post merge-up Signed-off-by: George Steel --- composer.lock | 152 +----------------------- psalm-baseline.xml | 285 --------------------------------------------- 2 files changed, 1 insertion(+), 436 deletions(-) diff --git a/composer.lock b/composer.lock index 1400d9dab..639e66436 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "d8c4880e9375fc4df0bb44fdb9436bf2", + "content-hash": "6f4f1dcd9aabd89a90c6f0ad6d25cc20", "packages": [ { "name": "laminas/laminas-escaper", @@ -1972,75 +1972,6 @@ ], "time": "2022-12-02T15:45:50+00:00" }, - { - "name": "laminas/laminas-mvc-plugin-flashmessenger", - "version": "1.9.0", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-mvc-plugin-flashmessenger.git", - "reference": "dc73bb6b56a0d74f9fdc0d24ec55a5f8c87c4cfa" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-mvc-plugin-flashmessenger/zipball/dc73bb6b56a0d74f9fdc0d24ec55a5f8c87c4cfa", - "reference": "dc73bb6b56a0d74f9fdc0d24ec55a5f8c87c4cfa", - "shasum": "" - }, - "require": { - "laminas/laminas-mvc": "^3.3", - "laminas/laminas-session": "^2.12.0", - "laminas/laminas-stdlib": "^3.6.4", - "laminas/laminas-view": "^2.13.1", - "php": "~8.0.0 || ~8.1.0 || ~8.2.0" - }, - "conflict": { - "laminas/laminas-mvc": "<3.0.0", - "zendframework/zend-mvc-plugin-flashmessenger": "*" - }, - "require-dev": { - "laminas/laminas-coding-standard": "~2.4.0", - "laminas/laminas-i18n": "^2.19.0", - "phpunit/phpunit": "^9.5.25", - "psalm/plugin-phpunit": "^0.17.0", - "vimeo/psalm": "^4.29.0" - }, - "type": "library", - "extra": { - "laminas": { - "component": "Laminas\\Mvc\\Plugin\\FlashMessenger" - } - }, - "autoload": { - "psr-4": { - "Laminas\\Mvc\\Plugin\\FlashMessenger\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Plugin for creating and exposing flash messages via laminas-mvc controllers", - "homepage": "https://laminas.dev", - "keywords": [ - "laminas", - "mvc" - ], - "support": { - "chat": "https://laminas.dev/chat", - "docs": "https://docs.laminas.dev/laminas-mvc-plugin-flashmessenger/", - "forum": "https://discourse.laminas.dev", - "issues": "https://github.com/laminas/laminas-mvc-plugin-flashmessenger/issues", - "rss": "https://github.com/laminas/laminas-mvc-plugin-flashmessenger/releases.atom", - "source": "https://github.com/laminas/laminas-mvc-plugin-flashmessenger" - }, - "funding": [ - { - "url": "https://funding.communitybridge.org/projects/laminas-project", - "type": "community_bridge" - } - ], - "time": "2022-10-22T12:47:30+00:00" - }, { "name": "laminas/laminas-navigation", "version": "2.18.1", @@ -2336,87 +2267,6 @@ ], "time": "2022-12-29T14:47:23+00:00" }, - { - "name": "laminas/laminas-session", - "version": "2.16.0", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-session.git", - "reference": "9c845a0361625d5775cad6f043716196201ad41f" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-session/zipball/9c845a0361625d5775cad6f043716196201ad41f", - "reference": "9c845a0361625d5775cad6f043716196201ad41f", - "shasum": "" - }, - "require": { - "laminas/laminas-eventmanager": "^3.5", - "laminas/laminas-servicemanager": "^3.15.1", - "laminas/laminas-stdlib": "^3.10.1", - "php": "~8.0.0 || ~8.1.0 || ~8.2.0" - }, - "conflict": { - "zendframework/zend-session": "*" - }, - "require-dev": { - "laminas/laminas-cache": "^3.8", - "laminas/laminas-cache-storage-adapter-memory": "^2.2", - "laminas/laminas-coding-standard": "~2.4.0", - "laminas/laminas-db": "^2.15", - "laminas/laminas-http": "^2.17.1", - "laminas/laminas-validator": "^2.28", - "mongodb/mongodb": "~1.13.0", - "phpunit/phpunit": "^9.5.26", - "psalm/plugin-phpunit": "^0.18.0", - "vimeo/psalm": "^5.0" - }, - "suggest": { - "laminas/laminas-cache": "Laminas\\Cache component", - "laminas/laminas-db": "Laminas\\Db component", - "laminas/laminas-http": "Laminas\\Http component", - "laminas/laminas-servicemanager": "Laminas\\ServiceManager component", - "laminas/laminas-validator": "Laminas\\Validator component", - "mongodb/mongodb": "If you want to use the MongoDB session save handler" - }, - "type": "library", - "extra": { - "laminas": { - "component": "Laminas\\Session", - "config-provider": "Laminas\\Session\\ConfigProvider" - } - }, - "autoload": { - "psr-4": { - "Laminas\\Session\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Object-oriented interface to PHP sessions and storage", - "homepage": "https://laminas.dev", - "keywords": [ - "laminas", - "session" - ], - "support": { - "chat": "https://laminas.dev/chat", - "docs": "https://docs.laminas.dev/laminas-session/", - "forum": "https://discourse.laminas.dev", - "issues": "https://github.com/laminas/laminas-session/issues", - "rss": "https://github.com/laminas/laminas-session/releases.atom", - "source": "https://github.com/laminas/laminas-session" - }, - "funding": [ - { - "url": "https://funding.communitybridge.org/projects/laminas-project", - "type": "community_bridge" - } - ], - "time": "2022-12-04T11:15:36+00:00" - }, { "name": "laminas/laminas-uri", "version": "2.10.0", diff --git a/psalm-baseline.xml b/psalm-baseline.xml index 0acb49a4f..751335303 100644 --- a/psalm-baseline.xml +++ b/psalm-baseline.xml @@ -146,46 +146,6 @@ $value[$k] - - - pluginFlashMessenger]]> - - - $item - - - $escapeHtmlHelper - $pluginFlashMessenger - - - $item - $messagesToPrint - - - $classes - $classes - - - $messagesToPrint[] - $messagesToPrint[] - - - $classes - $classes - $messagesToPrint[] - $messagesToPrint[] - escapeHtmlHelper]]> - - - (bool) $autoEscape - (string) $messageCloseString - (string) $messageOpenFormat - (string) $messageSeparatorString - - - escapeHtmlHelper]]> - - $flag === null @@ -419,26 +379,6 @@ is_string($content) - - - $htmlObject - - - $htmlObject($data, self::TYPE, $attribs, $params, $content) - - - string - - - $htmlObject($data, self::TYPE, $attribs, $params, $content) - - - plugin - - - plugin - - is_array($content) @@ -471,26 +411,6 @@ plugin - - - $htmlObject - - - $htmlObject($data, self::TYPE, $attribs, $params, $content) - - - string - - - $htmlObject($data, self::TYPE, $attribs, $params, $content) - - - plugin - - - plugin - - $value @@ -508,17 +428,6 @@ (bool) $useNamespaces - - - $response - - - null - - - response instanceof Response]]> - - plugin @@ -1092,7 +1001,6 @@ (string) $key (string) $key (string) $key - (string) $name containerClass($value)]]> @@ -1152,9 +1060,6 @@ - - null === static::$instance - containerClass($value)]]> @@ -1177,9 +1082,6 @@ (string) $key (string) $key - - new static() - @@ -1259,11 +1161,6 @@ - - - $cName - - @@ -1276,50 +1173,7 @@ $config - - - FlashMessenger - FlashMessenger - new FlashMessenger() - - - FlashMessengerFactory - - - - - - $flashMessenger - - - - - - - - - - $config - $configHelper - $controllerPluginManager - $flashMessenger - - - get - - - $container - - - $requestedName - - - - $this - $this - $this - (bool) $enabled @@ -1406,17 +1260,6 @@ clearVariables - - - int - - - options['errorLevel']]]> - - - $captureTo - - type]]> @@ -1500,29 +1343,6 @@ is_object($variables) - - - $values - - - $child - - - $child - $setting - $value - - - $setting - getFilterChain()->filter($values['result'])]]> - - - $model - - - $values - - @@ -1538,9 +1358,6 @@ - - void - $jsonpCallback @@ -1799,34 +1616,6 @@ plugin - - - $data - $stat - - - $mode - $offset - $opened_path - $options - $whence - - - pos]]> - pos]]> - pos]]> - - - $offset - $offset - $offset - - - break; - break; - break; - - Variables @@ -1982,75 +1771,6 @@ $test - - - $plugin - $plugin - mvcPluginClass]]> - - - FlashMessenger - [ - 'config' => $config, - ], - 'factories' => [ - 'ControllerPluginManager' => fn(ContainerInterface $services) => new PluginManager($services, [ - 'invokables' => [ - 'flashmessenger' => $this->mvcPluginClass, - ], - ]), - 'ViewHelperManager' => static fn(ContainerInterface $services) - => new HelperPluginManager($services), - ], - ])]]> - new FlashMessenger() - new FlashMessenger() - new FlashMessenger() - new FlashMessenger() - new FlashMessenger() - new FlashMessenger() - - - $displayInfo - $displayInfo - $displayInfo - $displayInfo - $helper - $helper - $helper - $helper - $helperPluginManager - $helperPluginManager - $helperPluginManager - $helperPluginManager - - - get - get - get - get - render - render - renderCurrent - renderCurrent - - - hasCurrentErrorMessages - hasCurrentInfoMessages - hasCurrentMessages - hasCurrentSuccessMessages - hasErrorMessages - hasInfoMessages - hasMessages - hasSuccessMessages - hasWarningMessages - render - render - renderCurrent - renderCurrent - - $value @@ -2148,11 +1868,6 @@ offsetSetName - - - HtmlFlash - - $escape($value) From 4ede0c584e72ba45df6bb459b6e1d91d37228ddd Mon Sep 17 00:00:00 2001 From: George Steel Date: Thu, 20 Jul 2023 10:20:39 +0100 Subject: [PATCH 36/58] Remove trailing spaces Signed-off-by: George Steel --- README.md | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/README.md b/README.md index 6d735e277..3803c8e51 100644 --- a/README.md +++ b/README.md @@ -3,19 +3,19 @@ [![Build Status](https://github.com/laminas/laminas-view/workflows/Continuous%20Integration/badge.svg)](https://github.com/laminas/laminas-view/actions?query=workflow%3A"Continuous+Integration") > ## 🇷🇺 Русским гражданам -> +> > Мы, участники Laminas, родились и живем в разных странах. У многих из нас есть друзья, родственники и коллеги как в России, так и в Украине. Некоторые из нас родились в России. Некоторые из нас живут в России. У некоторых бабушки и дедушки сражались с фашистами во Второй мировой войне. Здесь никто не поддерживает фашизм. -> +> > У одного из нас есть украинская родственница, которая спаслась из дома вместе с сыном. Поезд задержался из-за бомбежки на дороге впереди. У нас есть друзья, которые прячутся в бомбоубежищах. Мы с тревогой ждем весточки от них после воздушных налетов, которые беспорядочно наносят удары и попадают по больницам, школам, детским садам и домам. Мы не берем это из каких-либо СМИ. Мы наблюдаем это напрямую. -> +> > Вы доверяете нам достаточно, чтоб использовать наши программы, и мы просим вас довериться нам вновь. Мы нуждаемся в помощи. Выходите и протестуйте против этой бесполезной войны. Остановите кровопролитие. Скажите "Нет войне!" -> +> > ## 🇺🇸 To Citizens of Russia -> +> > We at Laminas come from all over the world. Many of us have friends, family and colleagues in both Russia and Ukraine. Some of us were born in Russia. Some of us currently live in Russia. Some have grandparents who fought Nazis in World War II. Nobody here supports fascism. -> +> > One team member has a Ukrainian relative who fled her home with her son. The train was delayed due to bombing on the road ahead. We have friends who are hiding in bomb shelters. We anxiously follow up on them after the air raids, which indiscriminately fire at hospitals, schools, kindergartens and houses. We're not taking this from any media. These are our actual experiences. -> +> > You trust us enough to use our software. We ask that you trust us to say the truth on this. We need your help. Go out and protest this unnecessary war. Stop the bloodshed. Say "stop the war!" laminas-view provides the “View” layer of the Laminas MVC system. It is a From f54c7e749ece479862e6b4559b3afe6dce76d2e6 Mon Sep 17 00:00:00 2001 From: George Steel Date: Wed, 18 Oct 2023 09:35:37 +0100 Subject: [PATCH 37/58] Refresh lock and reset baseline post merge-up Signed-off-by: George Steel --- composer.lock | 389 +++++++++++++++++++++++---------------------- psalm-baseline.xml | 183 +++++++-------------- 2 files changed, 252 insertions(+), 320 deletions(-) diff --git a/composer.lock b/composer.lock index 01d04bac4..fa7c47941 100644 --- a/composer.lock +++ b/composer.lock @@ -4,37 +4,37 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "6f4f1dcd9aabd89a90c6f0ad6d25cc20", + "content-hash": "b36d4ec2d2fe5e0e88fd8191ea7f6f17", "packages": [ { "name": "laminas/laminas-escaper", - "version": "2.12.0", + "version": "2.13.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-escaper.git", - "reference": "ee7a4c37bf3d0e8c03635d5bddb5bb3184ead490" + "reference": "af459883f4018d0f8a0c69c7a209daef3bf973ba" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-escaper/zipball/ee7a4c37bf3d0e8c03635d5bddb5bb3184ead490", - "reference": "ee7a4c37bf3d0e8c03635d5bddb5bb3184ead490", + "url": "https://api.github.com/repos/laminas/laminas-escaper/zipball/af459883f4018d0f8a0c69c7a209daef3bf973ba", + "reference": "af459883f4018d0f8a0c69c7a209daef3bf973ba", "shasum": "" }, "require": { "ext-ctype": "*", "ext-mbstring": "*", - "php": "^7.4 || ~8.0.0 || ~8.1.0 || ~8.2.0" + "php": "~8.1.0 || ~8.2.0 || ~8.3.0" }, "conflict": { "zendframework/zend-escaper": "*" }, "require-dev": { - "infection/infection": "^0.26.6", - "laminas/laminas-coding-standard": "~2.4.0", + "infection/infection": "^0.27.0", + "laminas/laminas-coding-standard": "~2.5.0", "maglnet/composer-require-checker": "^3.8.0", - "phpunit/phpunit": "^9.5.18", - "psalm/plugin-phpunit": "^0.17.0", - "vimeo/psalm": "^4.22.0" + "phpunit/phpunit": "^9.6.7", + "psalm/plugin-phpunit": "^0.18.4", + "vimeo/psalm": "^5.9" }, "type": "library", "autoload": { @@ -66,24 +66,24 @@ "type": "community_bridge" } ], - "time": "2022-10-10T10:11:09+00:00" + "time": "2023-10-10T08:35:13+00:00" }, { "name": "laminas/laminas-eventmanager", - "version": "3.10.0", + "version": "3.11.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-eventmanager.git", - "reference": "5a5114ab2d3fa4424faa46a2fb0a4e49a61f6eba" + "reference": "9cfa79ce247c567f05ce4b7c975c6bdf9698c5dd" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-eventmanager/zipball/5a5114ab2d3fa4424faa46a2fb0a4e49a61f6eba", - "reference": "5a5114ab2d3fa4424faa46a2fb0a4e49a61f6eba", + "url": "https://api.github.com/repos/laminas/laminas-eventmanager/zipball/9cfa79ce247c567f05ce4b7c975c6bdf9698c5dd", + "reference": "9cfa79ce247c567f05ce4b7c975c6bdf9698c5dd", "shasum": "" }, "require": { - "php": "~8.0.0 || ~8.1.0 || ~8.2.0" + "php": "~8.0.0 || ~8.1.0 || ~8.2.0 || ~8.3.0" }, "conflict": { "container-interop/container-interop": "<1.2", @@ -134,7 +134,7 @@ "type": "community_bridge" } ], - "time": "2023-01-11T19:52:45+00:00" + "time": "2023-10-10T08:29:58+00:00" }, { "name": "laminas/laminas-json", @@ -199,21 +199,21 @@ }, { "name": "laminas/laminas-servicemanager", - "version": "3.21.0", + "version": "3.22.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-servicemanager.git", - "reference": "625f2aa3bc6dd02688b2da5155b3a69870812bda" + "reference": "b4f547078af2ac3173cbe4a64e8fdfbd626c77ae" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-servicemanager/zipball/625f2aa3bc6dd02688b2da5155b3a69870812bda", - "reference": "625f2aa3bc6dd02688b2da5155b3a69870812bda", + "url": "https://api.github.com/repos/laminas/laminas-servicemanager/zipball/b4f547078af2ac3173cbe4a64e8fdfbd626c77ae", + "reference": "b4f547078af2ac3173cbe4a64e8fdfbd626c77ae", "shasum": "" }, "require": { "laminas/laminas-stdlib": "^3.17", - "php": "~8.1.0 || ~8.2.0", + "php": "~8.1.0 || ~8.2.0 || ~8.3.0", "psr/container": "^1.0" }, "conflict": { @@ -234,10 +234,9 @@ "laminas/laminas-code": "^4.10.0", "laminas/laminas-coding-standard": "~2.5.0", "laminas/laminas-container-config-test": "^0.8", - "laminas/laminas-dependency-plugin": "^2.2", "mikey179/vfsstream": "^1.6.11", "phpbench/phpbench": "^1.2.9", - "phpunit/phpunit": "^10.0.17", + "phpunit/phpunit": "^10.4", "psalm/plugin-phpunit": "^0.18.4", "vimeo/psalm": "^5.8.0" }, @@ -286,34 +285,34 @@ "type": "community_bridge" } ], - "time": "2023-05-14T12:24:54+00:00" + "time": "2023-10-10T21:23:36+00:00" }, { "name": "laminas/laminas-stdlib", - "version": "3.17.0", + "version": "3.18.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-stdlib.git", - "reference": "dd35c868075bad80b6718959740913e178eb4274" + "reference": "e85b29076c6216e7fc98e72b42dbe1bbc3b95ecf" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-stdlib/zipball/dd35c868075bad80b6718959740913e178eb4274", - "reference": "dd35c868075bad80b6718959740913e178eb4274", + "url": "https://api.github.com/repos/laminas/laminas-stdlib/zipball/e85b29076c6216e7fc98e72b42dbe1bbc3b95ecf", + "reference": "e85b29076c6216e7fc98e72b42dbe1bbc3b95ecf", "shasum": "" }, "require": { - "php": "~8.1.0 || ~8.2.0" + "php": "~8.1.0 || ~8.2.0 || ~8.3.0" }, "conflict": { "zendframework/zend-stdlib": "*" }, "require-dev": { "laminas/laminas-coding-standard": "^2.5", - "phpbench/phpbench": "^1.2.9", - "phpunit/phpunit": "^10.0.16", + "phpbench/phpbench": "^1.2.14", + "phpunit/phpunit": "^10.3.3", "psalm/plugin-phpunit": "^0.18.4", - "vimeo/psalm": "^5.8" + "vimeo/psalm": "^5.15.0" }, "type": "library", "autoload": { @@ -345,7 +344,7 @@ "type": "community_bridge" } ], - "time": "2023-03-20T13:51:37+00:00" + "time": "2023-09-19T10:15:21+00:00" }, { "name": "psr/container", @@ -687,16 +686,16 @@ }, { "name": "composer/pcre", - "version": "3.1.0", + "version": "3.1.1", "source": { "type": "git", "url": "https://github.com/composer/pcre.git", - "reference": "4bff79ddd77851fe3cdd11616ed3f92841ba5bd2" + "reference": "00104306927c7a0919b4ced2aaa6782c1e61a3c9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/pcre/zipball/4bff79ddd77851fe3cdd11616ed3f92841ba5bd2", - "reference": "4bff79ddd77851fe3cdd11616ed3f92841ba5bd2", + "url": "https://api.github.com/repos/composer/pcre/zipball/00104306927c7a0919b4ced2aaa6782c1e61a3c9", + "reference": "00104306927c7a0919b4ced2aaa6782c1e61a3c9", "shasum": "" }, "require": { @@ -738,7 +737,7 @@ ], "support": { "issues": "https://github.com/composer/pcre/issues", - "source": "https://github.com/composer/pcre/tree/3.1.0" + "source": "https://github.com/composer/pcre/tree/3.1.1" }, "funding": [ { @@ -754,20 +753,20 @@ "type": "tidelift" } ], - "time": "2022-11-17T09:50:14+00:00" + "time": "2023-10-11T07:11:09+00:00" }, { "name": "composer/semver", - "version": "3.3.2", + "version": "3.4.0", "source": { "type": "git", "url": "https://github.com/composer/semver.git", - "reference": "3953f23262f2bff1919fc82183ad9acb13ff62c9" + "reference": "35e8d0af4486141bc745f23a29cc2091eb624a32" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/composer/semver/zipball/3953f23262f2bff1919fc82183ad9acb13ff62c9", - "reference": "3953f23262f2bff1919fc82183ad9acb13ff62c9", + "url": "https://api.github.com/repos/composer/semver/zipball/35e8d0af4486141bc745f23a29cc2091eb624a32", + "reference": "35e8d0af4486141bc745f23a29cc2091eb624a32", "shasum": "" }, "require": { @@ -817,9 +816,9 @@ "versioning" ], "support": { - "irc": "irc://irc.freenode.org/composer", + "irc": "ircs://irc.libera.chat:6697/composer", "issues": "https://github.com/composer/semver/issues", - "source": "https://github.com/composer/semver/tree/3.3.2" + "source": "https://github.com/composer/semver/tree/3.4.0" }, "funding": [ { @@ -835,7 +834,7 @@ "type": "tidelift" } ], - "time": "2022-04-01T19:23:25+00:00" + "time": "2023-08-31T09:50:34+00:00" }, { "name": "composer/xdebug-handler", @@ -1311,22 +1310,22 @@ }, { "name": "laminas/laminas-config", - "version": "3.8.0", + "version": "3.9.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-config.git", - "reference": "46baad58d0b12cf98539e04334eff40a1fdfb9a0" + "reference": "e53717277f6c22b1c697a46473b9a5ec9a438efa" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-config/zipball/46baad58d0b12cf98539e04334eff40a1fdfb9a0", - "reference": "46baad58d0b12cf98539e04334eff40a1fdfb9a0", + "url": "https://api.github.com/repos/laminas/laminas-config/zipball/e53717277f6c22b1c697a46473b9a5ec9a438efa", + "reference": "e53717277f6c22b1c697a46473b9a5ec9a438efa", "shasum": "" }, "require": { "ext-json": "*", "laminas/laminas-stdlib": "^3.6", - "php": "~8.0.0 || ~8.1.0 || ~8.2.0", + "php": "~8.0.0 || ~8.1.0 || ~8.2.0 || ~8.3.0", "psr/container": "^1.0" }, "conflict": { @@ -1375,20 +1374,20 @@ "type": "community_bridge" } ], - "time": "2022-10-16T14:21:22+00:00" + "time": "2023-09-19T12:02:54+00:00" }, { "name": "laminas/laminas-feed", - "version": "2.21.0", + "version": "2.22.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-feed.git", - "reference": "52918789a417bc292ccd6fbb4b91bd78a65d50ab" + "reference": "669792b819fca7274698147ad7a2ecc1b0a9b141" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-feed/zipball/52918789a417bc292ccd6fbb4b91bd78a65d50ab", - "reference": "52918789a417bc292ccd6fbb4b91bd78a65d50ab", + "url": "https://api.github.com/repos/laminas/laminas-feed/zipball/669792b819fca7274698147ad7a2ecc1b0a9b141", + "reference": "669792b819fca7274698147ad7a2ecc1b0a9b141", "shasum": "" }, "require": { @@ -1396,24 +1395,24 @@ "ext-libxml": "*", "laminas/laminas-escaper": "^2.9", "laminas/laminas-stdlib": "^3.6", - "php": "~8.1.0 || ~8.2.0" + "php": "~8.1.0 || ~8.2.0 || ~8.3.0" }, "conflict": { "laminas/laminas-servicemanager": "<3.3", "zendframework/zend-feed": "*" }, "require-dev": { - "laminas/laminas-cache": "^2.13.2 || ^3.10.1", + "laminas/laminas-cache": "^2.13.2 || ^3.11", "laminas/laminas-cache-storage-adapter-memory": "^1.1.0 || ^2.2", "laminas/laminas-coding-standard": "~2.5.0", "laminas/laminas-db": "^2.18", "laminas/laminas-http": "^2.18", "laminas/laminas-servicemanager": "^3.21.0", - "laminas/laminas-validator": "^2.30.1", - "phpunit/phpunit": "^10.2.6", + "laminas/laminas-validator": "^2.38", + "phpunit/phpunit": "^10.3.1", "psalm/plugin-phpunit": "^0.18.4", "psr/http-message": "^2.0", - "vimeo/psalm": "^5.13.1" + "vimeo/psalm": "^5.14.1" }, "suggest": { "laminas/laminas-cache": "Laminas\\Cache component, for optionally caching feeds between requests", @@ -1455,7 +1454,7 @@ "type": "community_bridge" } ], - "time": "2023-07-24T09:21:16+00:00" + "time": "2023-10-11T20:16:37+00:00" }, { "name": "laminas/laminas-filter", @@ -1602,16 +1601,16 @@ }, { "name": "laminas/laminas-i18n", - "version": "2.23.0", + "version": "2.23.1", "source": { "type": "git", "url": "https://github.com/laminas/laminas-i18n.git", - "reference": "bb844a1141bb6e65d8889f5a08383f761a8270b2" + "reference": "970a2775732d56b89434ec283577096887e68167" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-i18n/zipball/bb844a1141bb6e65d8889f5a08383f761a8270b2", - "reference": "bb844a1141bb6e65d8889f5a08383f761a8270b2", + "url": "https://api.github.com/repos/laminas/laminas-i18n/zipball/970a2775732d56b89434ec283577096887e68167", + "reference": "970a2775732d56b89434ec283577096887e68167", "shasum": "" }, "require": { @@ -1683,7 +1682,7 @@ "type": "community_bridge" } ], - "time": "2023-05-16T23:22:24+00:00" + "time": "2023-10-09T12:00:55+00:00" }, { "name": "laminas/laminas-loader", @@ -2134,20 +2133,20 @@ }, { "name": "laminas/laminas-permissions-acl", - "version": "2.15.0", + "version": "2.16.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-permissions-acl.git", - "reference": "ea9f6643a624b3e847f7d637eb828498654f492e" + "reference": "9f85ee3b1940cd5a1c4151ca16fdb738c162480b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-permissions-acl/zipball/ea9f6643a624b3e847f7d637eb828498654f492e", - "reference": "ea9f6643a624b3e847f7d637eb828498654f492e", + "url": "https://api.github.com/repos/laminas/laminas-permissions-acl/zipball/9f85ee3b1940cd5a1c4151ca16fdb738c162480b", + "reference": "9f85ee3b1940cd5a1c4151ca16fdb738c162480b", "shasum": "" }, "require": { - "php": "~8.1.0 || ~8.2.0" + "php": "~8.1.0 || ~8.2.0 || ~8.3.0" }, "conflict": { "laminas/laminas-servicemanager": "<3.0", @@ -2194,7 +2193,7 @@ "type": "community_bridge" } ], - "time": "2023-05-29T19:28:02+00:00" + "time": "2023-10-18T07:50:34+00:00" }, { "name": "laminas/laminas-router", @@ -2327,22 +2326,22 @@ }, { "name": "laminas/laminas-validator", - "version": "2.35.0", + "version": "2.39.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-validator.git", - "reference": "7a4a30f6c526a518ba9af50e037c2f97cb595958" + "reference": "cec22e6f55fa68ec24e21c4f021fc1b2c3783c49" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-validator/zipball/7a4a30f6c526a518ba9af50e037c2f97cb595958", - "reference": "7a4a30f6c526a518ba9af50e037c2f97cb595958", + "url": "https://api.github.com/repos/laminas/laminas-validator/zipball/cec22e6f55fa68ec24e21c4f021fc1b2c3783c49", + "reference": "cec22e6f55fa68ec24e21c4f021fc1b2c3783c49", "shasum": "" }, "require": { "laminas/laminas-servicemanager": "^3.21.0", "laminas/laminas-stdlib": "^3.13", - "php": "~8.1.0 || ~8.2.0", + "php": "~8.1.0 || ~8.2.0 || ~8.3.0", "psr/http-message": "^1.0.1 || ^2.0.0" }, "conflict": { @@ -2355,11 +2354,11 @@ "laminas/laminas-i18n": "^2.23", "laminas/laminas-session": "^2.16", "laminas/laminas-uri": "^2.10.0", - "phpunit/phpunit": "^10.1.3", + "phpunit/phpunit": "^10.3.3", "psalm/plugin-phpunit": "^0.18.4", "psr/http-client": "^1.0.2", "psr/http-factory": "^1.0.2", - "vimeo/psalm": "^5.12" + "vimeo/psalm": "^5.15" }, "suggest": { "laminas/laminas-db": "Laminas\\Db component, required by the (No)RecordExists validator", @@ -2407,7 +2406,7 @@ "type": "community_bridge" } ], - "time": "2023-07-10T07:32:01+00:00" + "time": "2023-09-06T20:51:34+00:00" }, { "name": "myclabs/deep-copy", @@ -2521,16 +2520,16 @@ }, { "name": "nikic/php-parser", - "version": "v4.16.0", + "version": "v4.17.1", "source": { "type": "git", "url": "https://github.com/nikic/PHP-Parser.git", - "reference": "19526a33fb561ef417e822e85f08a00db4059c17" + "reference": "a6303e50c90c355c7eeee2c4a8b27fe8dc8fef1d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/19526a33fb561ef417e822e85f08a00db4059c17", - "reference": "19526a33fb561ef417e822e85f08a00db4059c17", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/a6303e50c90c355c7eeee2c4a8b27fe8dc8fef1d", + "reference": "a6303e50c90c355c7eeee2c4a8b27fe8dc8fef1d", "shasum": "" }, "require": { @@ -2571,9 +2570,9 @@ ], "support": { "issues": "https://github.com/nikic/PHP-Parser/issues", - "source": "https://github.com/nikic/PHP-Parser/tree/v4.16.0" + "source": "https://github.com/nikic/PHP-Parser/tree/v4.17.1" }, - "time": "2023-06-25T14:52:30+00:00" + "time": "2023-08-13T19:53:39+00:00" }, { "name": "phar-io/manifest", @@ -2897,16 +2896,16 @@ }, { "name": "phpunit/php-code-coverage", - "version": "10.1.3", + "version": "10.1.7", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "be1fe461fdc917de2a29a452ccf2657d325b443d" + "reference": "355324ca4980b8916c18b9db29f3ef484078f26e" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/be1fe461fdc917de2a29a452ccf2657d325b443d", - "reference": "be1fe461fdc917de2a29a452ccf2657d325b443d", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/355324ca4980b8916c18b9db29f3ef484078f26e", + "reference": "355324ca4980b8916c18b9db29f3ef484078f26e", "shasum": "" }, "require": { @@ -2963,7 +2962,7 @@ "support": { "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", "security": "https://github.com/sebastianbergmann/php-code-coverage/security/policy", - "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/10.1.3" + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/10.1.7" }, "funding": [ { @@ -2971,20 +2970,20 @@ "type": "github" } ], - "time": "2023-07-26T13:45:28+00:00" + "time": "2023-10-04T15:34:17+00:00" }, { "name": "phpunit/php-file-iterator", - "version": "4.0.2", + "version": "4.1.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-file-iterator.git", - "reference": "5647d65443818959172645e7ed999217360654b6" + "reference": "a95037b6d9e608ba092da1b23931e537cadc3c3c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/5647d65443818959172645e7ed999217360654b6", - "reference": "5647d65443818959172645e7ed999217360654b6", + "url": "https://api.github.com/repos/sebastianbergmann/php-file-iterator/zipball/a95037b6d9e608ba092da1b23931e537cadc3c3c", + "reference": "a95037b6d9e608ba092da1b23931e537cadc3c3c", "shasum": "" }, "require": { @@ -3024,7 +3023,7 @@ "support": { "issues": "https://github.com/sebastianbergmann/php-file-iterator/issues", "security": "https://github.com/sebastianbergmann/php-file-iterator/security/policy", - "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/4.0.2" + "source": "https://github.com/sebastianbergmann/php-file-iterator/tree/4.1.0" }, "funding": [ { @@ -3032,7 +3031,7 @@ "type": "github" } ], - "time": "2023-05-07T09:13:23+00:00" + "time": "2023-08-31T06:24:48+00:00" }, { "name": "phpunit/php-invoker", @@ -3099,16 +3098,16 @@ }, { "name": "phpunit/php-text-template", - "version": "3.0.0", + "version": "3.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-text-template.git", - "reference": "9f3d3709577a527025f55bcf0f7ab8052c8bb37d" + "reference": "0c7b06ff49e3d5072f057eb1fa59258bf287a748" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/9f3d3709577a527025f55bcf0f7ab8052c8bb37d", - "reference": "9f3d3709577a527025f55bcf0f7ab8052c8bb37d", + "url": "https://api.github.com/repos/sebastianbergmann/php-text-template/zipball/0c7b06ff49e3d5072f057eb1fa59258bf287a748", + "reference": "0c7b06ff49e3d5072f057eb1fa59258bf287a748", "shasum": "" }, "require": { @@ -3146,7 +3145,8 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/php-text-template/issues", - "source": "https://github.com/sebastianbergmann/php-text-template/tree/3.0.0" + "security": "https://github.com/sebastianbergmann/php-text-template/security/policy", + "source": "https://github.com/sebastianbergmann/php-text-template/tree/3.0.1" }, "funding": [ { @@ -3154,7 +3154,7 @@ "type": "github" } ], - "time": "2023-02-03T06:56:46+00:00" + "time": "2023-08-31T14:07:24+00:00" }, { "name": "phpunit/php-timer", @@ -3217,16 +3217,16 @@ }, { "name": "phpunit/phpunit", - "version": "10.2.6", + "version": "10.4.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "1c17815c129f133f3019cc18e8d0c8622e6d9bcd" + "reference": "62bd7af13d282deeb95650077d28ba3600ca321c" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/1c17815c129f133f3019cc18e8d0c8622e6d9bcd", - "reference": "1c17815c129f133f3019cc18e8d0c8622e6d9bcd", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/62bd7af13d282deeb95650077d28ba3600ca321c", + "reference": "62bd7af13d282deeb95650077d28ba3600ca321c", "shasum": "" }, "require": { @@ -3240,7 +3240,7 @@ "phar-io/manifest": "^2.0.3", "phar-io/version": "^3.0.2", "php": ">=8.1", - "phpunit/php-code-coverage": "^10.1.1", + "phpunit/php-code-coverage": "^10.1.5", "phpunit/php-file-iterator": "^4.0", "phpunit/php-invoker": "^4.0", "phpunit/php-text-template": "^3.0", @@ -3250,8 +3250,8 @@ "sebastian/comparator": "^5.0", "sebastian/diff": "^5.0", "sebastian/environment": "^6.0", - "sebastian/exporter": "^5.0", - "sebastian/global-state": "^6.0", + "sebastian/exporter": "^5.1", + "sebastian/global-state": "^6.0.1", "sebastian/object-enumerator": "^5.0", "sebastian/recursion-context": "^5.0", "sebastian/type": "^4.0", @@ -3266,7 +3266,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "10.2-dev" + "dev-main": "10.4-dev" } }, "autoload": { @@ -3298,7 +3298,7 @@ "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", "security": "https://github.com/sebastianbergmann/phpunit/security/policy", - "source": "https://github.com/sebastianbergmann/phpunit/tree/10.2.6" + "source": "https://github.com/sebastianbergmann/phpunit/tree/10.4.1" }, "funding": [ { @@ -3314,7 +3314,7 @@ "type": "tidelift" } ], - "time": "2023-07-17T12:08:28+00:00" + "time": "2023-10-08T05:01:11+00:00" }, { "name": "psalm/plugin-phpunit", @@ -3648,16 +3648,16 @@ }, { "name": "sebastian/comparator", - "version": "5.0.0", + "version": "5.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/comparator.git", - "reference": "72f01e6586e0caf6af81297897bd112eb7e9627c" + "reference": "2db5010a484d53ebf536087a70b4a5423c102372" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/72f01e6586e0caf6af81297897bd112eb7e9627c", - "reference": "72f01e6586e0caf6af81297897bd112eb7e9627c", + "url": "https://api.github.com/repos/sebastianbergmann/comparator/zipball/2db5010a484d53ebf536087a70b4a5423c102372", + "reference": "2db5010a484d53ebf536087a70b4a5423c102372", "shasum": "" }, "require": { @@ -3668,7 +3668,7 @@ "sebastian/exporter": "^5.0" }, "require-dev": { - "phpunit/phpunit": "^10.0" + "phpunit/phpunit": "^10.3" }, "type": "library", "extra": { @@ -3712,7 +3712,8 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/comparator/issues", - "source": "https://github.com/sebastianbergmann/comparator/tree/5.0.0" + "security": "https://github.com/sebastianbergmann/comparator/security/policy", + "source": "https://github.com/sebastianbergmann/comparator/tree/5.0.1" }, "funding": [ { @@ -3720,20 +3721,20 @@ "type": "github" } ], - "time": "2023-02-03T07:07:16+00:00" + "time": "2023-08-14T13:18:12+00:00" }, { "name": "sebastian/complexity", - "version": "3.0.0", + "version": "3.1.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/complexity.git", - "reference": "e67d240970c9dc7ea7b2123a6d520e334dd61dc6" + "reference": "68cfb347a44871f01e33ab0ef8215966432f6957" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/e67d240970c9dc7ea7b2123a6d520e334dd61dc6", - "reference": "e67d240970c9dc7ea7b2123a6d520e334dd61dc6", + "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/68cfb347a44871f01e33ab0ef8215966432f6957", + "reference": "68cfb347a44871f01e33ab0ef8215966432f6957", "shasum": "" }, "require": { @@ -3746,7 +3747,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "3.0-dev" + "dev-main": "3.1-dev" } }, "autoload": { @@ -3769,7 +3770,8 @@ "homepage": "https://github.com/sebastianbergmann/complexity", "support": { "issues": "https://github.com/sebastianbergmann/complexity/issues", - "source": "https://github.com/sebastianbergmann/complexity/tree/3.0.0" + "security": "https://github.com/sebastianbergmann/complexity/security/policy", + "source": "https://github.com/sebastianbergmann/complexity/tree/3.1.0" }, "funding": [ { @@ -3777,7 +3779,7 @@ "type": "github" } ], - "time": "2023-02-03T06:59:47+00:00" + "time": "2023-09-28T11:50:59+00:00" }, { "name": "sebastian/diff", @@ -3912,16 +3914,16 @@ }, { "name": "sebastian/exporter", - "version": "5.0.0", + "version": "5.1.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/exporter.git", - "reference": "f3ec4bf931c0b31e5b413f5b4fc970a7d03338c0" + "reference": "64f51654862e0f5e318db7e9dcc2292c63cdbddc" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/f3ec4bf931c0b31e5b413f5b4fc970a7d03338c0", - "reference": "f3ec4bf931c0b31e5b413f5b4fc970a7d03338c0", + "url": "https://api.github.com/repos/sebastianbergmann/exporter/zipball/64f51654862e0f5e318db7e9dcc2292c63cdbddc", + "reference": "64f51654862e0f5e318db7e9dcc2292c63cdbddc", "shasum": "" }, "require": { @@ -3935,7 +3937,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "5.0-dev" + "dev-main": "5.1-dev" } }, "autoload": { @@ -3977,7 +3979,8 @@ ], "support": { "issues": "https://github.com/sebastianbergmann/exporter/issues", - "source": "https://github.com/sebastianbergmann/exporter/tree/5.0.0" + "security": "https://github.com/sebastianbergmann/exporter/security/policy", + "source": "https://github.com/sebastianbergmann/exporter/tree/5.1.1" }, "funding": [ { @@ -3985,7 +3988,7 @@ "type": "github" } ], - "time": "2023-02-03T07:06:49+00:00" + "time": "2023-09-24T13:22:09+00:00" }, { "name": "sebastian/global-state", @@ -4051,16 +4054,16 @@ }, { "name": "sebastian/lines-of-code", - "version": "2.0.0", + "version": "2.0.1", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/lines-of-code.git", - "reference": "17c4d940ecafb3d15d2cf916f4108f664e28b130" + "reference": "649e40d279e243d985aa8fb6e74dd5bb28dc185d" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/lines-of-code/zipball/17c4d940ecafb3d15d2cf916f4108f664e28b130", - "reference": "17c4d940ecafb3d15d2cf916f4108f664e28b130", + "url": "https://api.github.com/repos/sebastianbergmann/lines-of-code/zipball/649e40d279e243d985aa8fb6e74dd5bb28dc185d", + "reference": "649e40d279e243d985aa8fb6e74dd5bb28dc185d", "shasum": "" }, "require": { @@ -4096,7 +4099,8 @@ "homepage": "https://github.com/sebastianbergmann/lines-of-code", "support": { "issues": "https://github.com/sebastianbergmann/lines-of-code/issues", - "source": "https://github.com/sebastianbergmann/lines-of-code/tree/2.0.0" + "security": "https://github.com/sebastianbergmann/lines-of-code/security/policy", + "source": "https://github.com/sebastianbergmann/lines-of-code/tree/2.0.1" }, "funding": [ { @@ -4104,7 +4108,7 @@ "type": "github" } ], - "time": "2023-02-03T07:08:02+00:00" + "time": "2023-08-31T09:25:50+00:00" }, { "name": "sebastian/object-enumerator", @@ -4573,16 +4577,16 @@ }, { "name": "symfony/console", - "version": "v6.3.2", + "version": "v6.3.4", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "aa5d64ad3f63f2e48964fc81ee45cb318a723898" + "reference": "eca495f2ee845130855ddf1cf18460c38966c8b6" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/aa5d64ad3f63f2e48964fc81ee45cb318a723898", - "reference": "aa5d64ad3f63f2e48964fc81ee45cb318a723898", + "url": "https://api.github.com/repos/symfony/console/zipball/eca495f2ee845130855ddf1cf18460c38966c8b6", + "reference": "eca495f2ee845130855ddf1cf18460c38966c8b6", "shasum": "" }, "require": { @@ -4643,7 +4647,7 @@ "terminal" ], "support": { - "source": "https://github.com/symfony/console/tree/v6.3.2" + "source": "https://github.com/symfony/console/tree/v6.3.4" }, "funding": [ { @@ -4659,7 +4663,7 @@ "type": "tidelift" } ], - "time": "2023-07-19T20:17:28+00:00" + "time": "2023-08-16T10:10:12+00:00" }, { "name": "symfony/deprecation-contracts", @@ -4793,16 +4797,16 @@ }, { "name": "symfony/polyfill-ctype", - "version": "v1.27.0", + "version": "v1.28.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-ctype.git", - "reference": "5bbc823adecdae860bb64756d639ecfec17b050a" + "reference": "ea208ce43cbb04af6867b4fdddb1bdbf84cc28cb" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/5bbc823adecdae860bb64756d639ecfec17b050a", - "reference": "5bbc823adecdae860bb64756d639ecfec17b050a", + "url": "https://api.github.com/repos/symfony/polyfill-ctype/zipball/ea208ce43cbb04af6867b4fdddb1bdbf84cc28cb", + "reference": "ea208ce43cbb04af6867b4fdddb1bdbf84cc28cb", "shasum": "" }, "require": { @@ -4817,7 +4821,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.27-dev" + "dev-main": "1.28-dev" }, "thanks": { "name": "symfony/polyfill", @@ -4855,7 +4859,7 @@ "portable" ], "support": { - "source": "https://github.com/symfony/polyfill-ctype/tree/v1.27.0" + "source": "https://github.com/symfony/polyfill-ctype/tree/v1.28.0" }, "funding": [ { @@ -4871,20 +4875,20 @@ "type": "tidelift" } ], - "time": "2022-11-03T14:55:06+00:00" + "time": "2023-01-26T09:26:14+00:00" }, { "name": "symfony/polyfill-intl-grapheme", - "version": "v1.27.0", + "version": "v1.28.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-grapheme.git", - "reference": "511a08c03c1960e08a883f4cffcacd219b758354" + "reference": "875e90aeea2777b6f135677f618529449334a612" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-intl-grapheme/zipball/511a08c03c1960e08a883f4cffcacd219b758354", - "reference": "511a08c03c1960e08a883f4cffcacd219b758354", + "url": "https://api.github.com/repos/symfony/polyfill-intl-grapheme/zipball/875e90aeea2777b6f135677f618529449334a612", + "reference": "875e90aeea2777b6f135677f618529449334a612", "shasum": "" }, "require": { @@ -4896,7 +4900,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.27-dev" + "dev-main": "1.28-dev" }, "thanks": { "name": "symfony/polyfill", @@ -4936,7 +4940,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-intl-grapheme/tree/v1.27.0" + "source": "https://github.com/symfony/polyfill-intl-grapheme/tree/v1.28.0" }, "funding": [ { @@ -4952,20 +4956,20 @@ "type": "tidelift" } ], - "time": "2022-11-03T14:55:06+00:00" + "time": "2023-01-26T09:26:14+00:00" }, { "name": "symfony/polyfill-intl-normalizer", - "version": "v1.27.0", + "version": "v1.28.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-intl-normalizer.git", - "reference": "19bd1e4fcd5b91116f14d8533c57831ed00571b6" + "reference": "8c4ad05dd0120b6a53c1ca374dca2ad0a1c4ed92" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-intl-normalizer/zipball/19bd1e4fcd5b91116f14d8533c57831ed00571b6", - "reference": "19bd1e4fcd5b91116f14d8533c57831ed00571b6", + "url": "https://api.github.com/repos/symfony/polyfill-intl-normalizer/zipball/8c4ad05dd0120b6a53c1ca374dca2ad0a1c4ed92", + "reference": "8c4ad05dd0120b6a53c1ca374dca2ad0a1c4ed92", "shasum": "" }, "require": { @@ -4977,7 +4981,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.27-dev" + "dev-main": "1.28-dev" }, "thanks": { "name": "symfony/polyfill", @@ -5020,7 +5024,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-intl-normalizer/tree/v1.27.0" + "source": "https://github.com/symfony/polyfill-intl-normalizer/tree/v1.28.0" }, "funding": [ { @@ -5036,20 +5040,20 @@ "type": "tidelift" } ], - "time": "2022-11-03T14:55:06+00:00" + "time": "2023-01-26T09:26:14+00:00" }, { "name": "symfony/polyfill-mbstring", - "version": "v1.27.0", + "version": "v1.28.0", "source": { "type": "git", "url": "https://github.com/symfony/polyfill-mbstring.git", - "reference": "8ad114f6b39e2c98a8b0e3bd907732c207c2b534" + "reference": "42292d99c55abe617799667f454222c54c60e229" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/8ad114f6b39e2c98a8b0e3bd907732c207c2b534", - "reference": "8ad114f6b39e2c98a8b0e3bd907732c207c2b534", + "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/42292d99c55abe617799667f454222c54c60e229", + "reference": "42292d99c55abe617799667f454222c54c60e229", "shasum": "" }, "require": { @@ -5064,7 +5068,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "1.27-dev" + "dev-main": "1.28-dev" }, "thanks": { "name": "symfony/polyfill", @@ -5103,7 +5107,7 @@ "shim" ], "support": { - "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.27.0" + "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.28.0" }, "funding": [ { @@ -5119,7 +5123,7 @@ "type": "tidelift" } ], - "time": "2022-11-03T14:55:06+00:00" + "time": "2023-07-28T09:04:16+00:00" }, { "name": "symfony/service-contracts", @@ -5206,16 +5210,16 @@ }, { "name": "symfony/string", - "version": "v6.3.2", + "version": "v6.3.5", "source": { "type": "git", "url": "https://github.com/symfony/string.git", - "reference": "53d1a83225002635bca3482fcbf963001313fb68" + "reference": "13d76d0fb049051ed12a04bef4f9de8715bea339" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/string/zipball/53d1a83225002635bca3482fcbf963001313fb68", - "reference": "53d1a83225002635bca3482fcbf963001313fb68", + "url": "https://api.github.com/repos/symfony/string/zipball/13d76d0fb049051ed12a04bef4f9de8715bea339", + "reference": "13d76d0fb049051ed12a04bef4f9de8715bea339", "shasum": "" }, "require": { @@ -5272,7 +5276,7 @@ "utf8" ], "support": { - "source": "https://github.com/symfony/string/tree/v6.3.2" + "source": "https://github.com/symfony/string/tree/v6.3.5" }, "funding": [ { @@ -5288,7 +5292,7 @@ "type": "tidelift" } ], - "time": "2023-07-05T08:41:27+00:00" + "time": "2023-09-18T10:38:32+00:00" }, { "name": "theseer/tokenizer", @@ -5342,16 +5346,16 @@ }, { "name": "vimeo/psalm", - "version": "5.14.0", + "version": "5.15.0", "source": { "type": "git", "url": "https://github.com/vimeo/psalm.git", - "reference": "b2942cefed8443002bd3f245c4cd0a54193716d8" + "reference": "5c774aca4746caf3d239d9c8cadb9f882ca29352" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/vimeo/psalm/zipball/b2942cefed8443002bd3f245c4cd0a54193716d8", - "reference": "b2942cefed8443002bd3f245c4cd0a54193716d8", + "url": "https://api.github.com/repos/vimeo/psalm/zipball/5c774aca4746caf3d239d9c8cadb9f882ca29352", + "reference": "5c774aca4746caf3d239d9c8cadb9f882ca29352", "shasum": "" }, "require": { @@ -5379,6 +5383,9 @@ "symfony/console": "^4.1.6 || ^5.0 || ^6.0", "symfony/filesystem": "^5.4 || ^6.0" }, + "conflict": { + "nikic/php-parser": "4.17.0" + }, "provide": { "psalm/psalm": "self.version" }, @@ -5442,9 +5449,9 @@ ], "support": { "issues": "https://github.com/vimeo/psalm/issues", - "source": "https://github.com/vimeo/psalm/tree/5.14.0" + "source": "https://github.com/vimeo/psalm/tree/5.15.0" }, - "time": "2023-07-30T20:18:56+00:00" + "time": "2023-08-20T23:07:30+00:00" }, { "name": "webimpress/coding-standard", @@ -5634,5 +5641,5 @@ "platform-overrides": { "php": "8.1.99" }, - "plugin-api-version": "2.3.0" + "plugin-api-version": "2.6.0" } diff --git a/psalm-baseline.xml b/psalm-baseline.xml index 54e709c03..1c86d84ee 100644 --- a/psalm-baseline.xml +++ b/psalm-baseline.xml @@ -1,23 +1,5 @@ - - - - $templatePath - - - $file - getExtension()]]> - $templatePath - - - $file - $files[] - - - getExtension - getPathname - - + $closingBracket @@ -30,8 +12,6 @@ $closingBracket $closingBracket $closingBracket - $closingBracket - $closingBracket $val @@ -1086,18 +1066,12 @@ $viewModelHelper - $childModel viewModelHelper]]> ViewModel - false|Model - - captureTo - - $childModel viewModelHelper]]> @@ -1284,11 +1258,6 @@ $captureTo - - - IteratorAggregate - - gettype($variables) @@ -1300,29 +1269,9 @@ $key - - $children[] - - $child - $children - $children[] $value - - array - - - captureTo - getChildrenByCaptureTo - - - getChildrenByCaptureTo($capture)]]> - - - $children - $children - $variables[$name] @@ -1359,23 +1308,14 @@ $jsonpCallback - $child $nameOrModel $child - - $values[$captureTo] - - $captureTo - $child $value - - captureTo - $childValues $children @@ -1398,9 +1338,15 @@ gettype($helpers) gettype($variables) + + __templateResolver->resolve($name, $this)]]> + $values + + string|Resolver + $__vars __template]]> @@ -1437,7 +1383,6 @@ string - string|Resolver getArrayCopy @@ -1448,7 +1393,6 @@ __filterChain->filter($this->__content)]]> - __templateResolver->resolve($name, $this)]]> __templateResolver]]> @@ -1484,57 +1428,48 @@ - - IteratorAggregate - - - $resolver - $resource + + lastLookupFailure]]> + lastLookupFailure]]> lastLookupFailure]]> lastLookupFailure]]> lastSuccessfulResolver]]> - - - false|string - - - resolve - - - $resource - - - null - - - $lastSuccessfulResolver - + lastSuccessfulResolver]]> + lastSuccessfulResolver]]> + - - $prefix - - - $result - + + resolve + + + (string) $prefix + - - - is_string($nameOrMap) + is_iterable($map) + is_iterable($map) - - IteratorAggregate - - - false|string - - - map[$name]]]> - + + map, $map)]]> + + + + is_string($path) + + + static::FAILURE_NOT_FOUND + static::FAILURE_NO_PATHS + + + lastLookupFailure]]> + lastLookupFailure]]> + lastLookupFailure]]> + lastLookupFailure]]> + is_string($path) @@ -1543,21 +1478,11 @@ false - $value - $value - $value - $value + + + - - lastLookupFailure]]> - lastLookupFailure]]> - $value - - - paths]]> - - (bool) $flag (bool) $flag (string) $defaultSuffix @@ -1652,17 +1577,9 @@ $request $response - - $child - - $child $oldResult - - setOption - terminate - $oldResult @@ -2553,11 +2470,19 @@ $model - - - $test - $test - + + + assertNull + + + + + TemplatePathStack::FAILURE_NOT_FOUND + TemplatePathStack::FAILURE_NO_PATHS + + + + From ac8c9264e2b5ac90257e5f3440d0b79d94d1b4cd Mon Sep 17 00:00:00 2001 From: George Steel Date: Wed, 18 Oct 2023 10:04:47 +0100 Subject: [PATCH 38/58] Duplicate docs tree to v3 and update redirect maps Signed-off-by: George Steel --- .../v3/application-integration/stand-alone.md | 210 +++++ .../setting-module-specific-layouts.md | 159 ++++ docs/book/v3/helpers/advanced-usage.md | 276 +++++++ docs/book/v3/helpers/asset.md | 78 ++ docs/book/v3/helpers/base-path.md | 37 + docs/book/v3/helpers/cycle.md | 103 +++ docs/book/v3/helpers/doctype.md | 150 ++++ docs/book/v3/helpers/escape.md | 249 ++++++ docs/book/v3/helpers/gravatar-image.md | 90 ++ docs/book/v3/helpers/head-link.md | 68 ++ docs/book/v3/helpers/head-meta.md | 158 ++++ docs/book/v3/helpers/head-script.md | 159 ++++ docs/book/v3/helpers/head-style.md | 226 +++++ docs/book/v3/helpers/head-title.md | 220 +++++ docs/book/v3/helpers/html-attributes.md | 148 ++++ docs/book/v3/helpers/html-list.md | 130 +++ docs/book/v3/helpers/html-object.md | 71 ++ docs/book/v3/helpers/html-tag.md | 106 +++ docs/book/v3/helpers/identity.md | 49 ++ docs/book/v3/helpers/inline-script.md | 75 ++ docs/book/v3/helpers/intro.md | 121 +++ docs/book/v3/helpers/json.md | 21 + docs/book/v3/helpers/layout.md | 60 ++ docs/book/v3/helpers/partial.md | 134 +++ docs/book/v3/helpers/placeholder.md | 171 ++++ docs/book/v3/helpers/url.md | 238 ++++++ docs/book/v3/php-renderer.md | 382 +++++++++ docs/book/v3/quick-start.md | 781 ++++++++++++++++++ docs/book/v3/view-event.md | 131 +++ docs/book/v3/view-scripts.md | 99 +++ mkdocs.yml | 98 ++- 31 files changed, 4968 insertions(+), 30 deletions(-) create mode 100644 docs/book/v3/application-integration/stand-alone.md create mode 100644 docs/book/v3/cookbook/setting-module-specific-layouts.md create mode 100644 docs/book/v3/helpers/advanced-usage.md create mode 100644 docs/book/v3/helpers/asset.md create mode 100644 docs/book/v3/helpers/base-path.md create mode 100644 docs/book/v3/helpers/cycle.md create mode 100644 docs/book/v3/helpers/doctype.md create mode 100644 docs/book/v3/helpers/escape.md create mode 100644 docs/book/v3/helpers/gravatar-image.md create mode 100644 docs/book/v3/helpers/head-link.md create mode 100644 docs/book/v3/helpers/head-meta.md create mode 100644 docs/book/v3/helpers/head-script.md create mode 100644 docs/book/v3/helpers/head-style.md create mode 100644 docs/book/v3/helpers/head-title.md create mode 100644 docs/book/v3/helpers/html-attributes.md create mode 100644 docs/book/v3/helpers/html-list.md create mode 100644 docs/book/v3/helpers/html-object.md create mode 100644 docs/book/v3/helpers/html-tag.md create mode 100644 docs/book/v3/helpers/identity.md create mode 100644 docs/book/v3/helpers/inline-script.md create mode 100644 docs/book/v3/helpers/intro.md create mode 100644 docs/book/v3/helpers/json.md create mode 100644 docs/book/v3/helpers/layout.md create mode 100644 docs/book/v3/helpers/partial.md create mode 100644 docs/book/v3/helpers/placeholder.md create mode 100644 docs/book/v3/helpers/url.md create mode 100644 docs/book/v3/php-renderer.md create mode 100644 docs/book/v3/quick-start.md create mode 100644 docs/book/v3/view-event.md create mode 100644 docs/book/v3/view-scripts.md diff --git a/docs/book/v3/application-integration/stand-alone.md b/docs/book/v3/application-integration/stand-alone.md new file mode 100644 index 000000000..6cc89d49c --- /dev/null +++ b/docs/book/v3/application-integration/stand-alone.md @@ -0,0 +1,210 @@ +# Stand-Alone + +The view and all view-helpers of laminas-view can also be used stand-alone. + +## The View + +The examples uses the following directory structure: + +```treeview +./ +|-- public/ +| `-- index.php +`-- templates/ + |-- index.phtml + `-- layout.phtml +``` + +### Basic Example + +#### Setup + +[Create a renderer, set a resolver for templates](../php-renderer.md#usage) +and initialize the view in `public/index.php`: + +```php +// Create template resolver +$templateResolver = new Laminas\View\Resolver\TemplatePathStack([ + 'script_paths' => [__DIR__ . '/../templates'], +]); + +// Create the renderer +$renderer = new Laminas\View\Renderer\PhpRenderer(); +$renderer->setResolver($templateResolver); + +// Initialize the view +$view = new Laminas\View\View(); +$view->getEventManager()->attach( + Laminas\View\ViewEvent::EVENT_RENDERER, + static function () use ($renderer) { + return $renderer; + } +); +``` + +#### Create View Script + +[Create a view script](../view-scripts.md) in `templates/index.phtml`: + +```php + +

    +``` + +#### Create View Model and render Output + +Extend the script in `public/index.php` to add a [view model](../quick-start.md): + +```php +$viewModel = new Laminas\View\Model\ViewModel(['headline' => 'Example']); +$viewModel->setTemplate('index'); + +// Set the return type to get the rendered content +$viewModel->setOption('has_parent', true); + +echo $view->render($viewModel); //

    Example

    +``` + +
    Show full code example + +```php + [__DIR__ . '/../templates'], +]); + +// Create the renderer +$renderer = new Laminas\View\Renderer\PhpRenderer(); +$renderer->setResolver($templateResolver); + +// Initialize the view +$view = new Laminas\View\View(); +$view->getEventManager()->attach( + Laminas\View\ViewEvent::EVENT_RENDERER, + static function () use ($renderer) { + return $renderer; + } +); + +// Create view model +$viewModel = new Laminas\View\Model\ViewModel(['headline' => 'Example']); +$viewModel->setTemplate('index'); + +// Set the return type to get the rendered content +$viewModel->setOption('has_parent', true); + +// Render +echo $view->render($viewModel); +``` + + +
    + +### Example with Layout + +#### Add Layout Script + +Create a new file `templates/layout.phtml` and add the following content: + +```php + + + + +``` + +#### Create Layout Model and render Output + +Update the script in `public/index.php` to add a view model for layout: + +```php +// Create layout model +$layout = new Laminas\View\Model\ViewModel(); +$layout->setTemplate('layout'); + +// Set the return type to get the rendered content +$layout->setOption('has_parent', true); + +// Add previous view model as child +$layout->addChild($viewModel); + +// Render +echo $view->render($layout); +``` + + +
    Show full code example + +```php + [__DIR__ . '/../templates'], +]); + +// Create the renderer +$renderer = new Laminas\View\Renderer\PhpRenderer(); +$renderer->setResolver($templateResolver); + +// Initialize the view +$view = new Laminas\View\View(); +$view->getEventManager()->attach( + Laminas\View\ViewEvent::EVENT_RENDERER, + static function () use ($renderer) { + return $renderer; + } +); + +// Create view model +$viewModel = new Laminas\View\Model\ViewModel(['headline' => 'Example']); +$viewModel->setTemplate('index'); + +// Create layout model +$layout = new Laminas\View\Model\ViewModel(); +$layout->setTemplate('layout'); + +// Set the return type to get the rendered content +$layout->setOption('has_parent', true); + +// Add previous view model as child +$layout->addChild($viewModel); + +// Render +echo $view->render($layout); +``` + + +
    + +## View Helpers + +### Setup + +Create the renderer: + +```php +$renderer = new Laminas\View\Renderer\PhpRenderer(); +``` + +### Using Helper + +```php +echo $renderer->doctype(Laminas\View\Helper\Doctype::HTML5); // +``` diff --git a/docs/book/v3/cookbook/setting-module-specific-layouts.md b/docs/book/v3/cookbook/setting-module-specific-layouts.md new file mode 100644 index 000000000..d344a6d3a --- /dev/null +++ b/docs/book/v3/cookbook/setting-module-specific-layouts.md @@ -0,0 +1,159 @@ +# Setting module-specific Layouts + +The following example shows how to set a template for the layout based on a +module name in a laminas-mvc based application. The example uses a listener that +listens on the +[`Laminas\Mvc\MvcEvent::EVENT_RENDER` event](https://docs.laminas.dev/laminas-mvc/mvc-event/#mvceventevent_render-render) +and uses the +[`Laminas\Router\RouteMatch` object](https://docs.laminas.dev/laminas-mvc/routing/#routing) +to get the called controller from the current request. + +## Create Listener + +Create a listener as a separate class, e.g. +`module/Admin/src/Listener/LayoutListener.php`: + +```php +namespace Admin\Listener; + +use Laminas\EventManager\AbstractListenerAggregate; +use Laminas\EventManager\EventManagerInterface; +use Laminas\Filter\FilterChain; +use Laminas\Filter\FilterInterface; +use Laminas\Filter\StringToLower; +use Laminas\Filter\Word\CamelCaseToDash; +use Laminas\Mvc\MvcEvent; +use Laminas\View\Resolver\TemplateMapResolver; + +class LayoutListener extends AbstractListenerAggregate +{ + /** @var TemplateMapResolver */ + private $templateMapResolver; + + /** @var FilterInterface */ + private $filter; + + public function __construct(TemplateMapResolver $templateMapResolver) + { + $this->templateMapResolver = $templateMapResolver; + $this->filter = (new FilterChain()) + ->attach(new CamelCaseToDash()) + ->attach(new StringToLower()); + } + + public function attach(EventManagerInterface $events, $priority = 1) + { + $this->listeners[] = $events->attach( + MvcEvent::EVENT_RENDER, + [$this, 'setLayout'] + ); + } + + public function setLayout(MvcEvent $event) : void + { + // Get and check the route match object + $routeMatch = $event->getRouteMatch(); + if (! $routeMatch) { + return; + } + + // Get and check the parameter for current controller + $controller = $routeMatch->getParam('controller'); + if (! $controller) { + return; + } + + // Extract module name + $module = substr($controller, 0, strpos($controller, '\\')); + + // Convert the module name from camel case to a lower string with dashes + $name = 'layout/' . $this->filter->filter($module); + + // Has the resolver an entry / layout with the given name? + if (! $this->templateMapResolver->has($name)) { + return; + } + + // Get root view model + $layoutViewModel = $event->getViewModel(); + + // Rendering without layout? + if ($layoutViewModel->terminate()) { + return; + } + + // Change template + $layoutViewModel->setTemplate($name); + } +} +``` + +## Register Listener + +Extend the module class to register the listener, e.g. +`module/Admin/Module.php`: + +```php +namespace Admin; + +use Admin\Listener\LayoutListener; +use Laminas\Mvc\MvcEvent; +use Laminas\View\Resolver\TemplateMapResolver; + +class Module +{ + public function onBootstrap(MvcEvent $event) : void + { + $application = $event->getApplication(); + + /** @var TemplateMapResolver $templateMapResolver */ + $templateMapResolver = $application->getServiceManager()->get( + 'ViewTemplateMapResolver' + ); + + // Create and register layout listener + $listener = new LayoutListener($templateMapResolver); + $listener->attach($application->getEventManager()); + } + + // … +} +``` + +> More information on registering module-specific listeners can be found in the +> [documentation of laminas-mvc](https://docs.laminas.dev/laminas-mvc/examples/#registering-module-specific-listeners). + +## Add Template Scripts to the Configuration + +Extend the configuration of a module to add the specific layout script, e.g. +`module/Admin/config/module.config.php`: + +```php +return [ + // Add the following array + 'view_manager' => [ + 'template_map' => [ + 'layout/admin' => __DIR__ . '/../view/layout/admin.phtml', + ], + ], + // … +]; +``` + +And in another module, e.g. `module/Album/config/module.config.php`: + +```php +return [ + // Add the following array + 'view_manager' => [ + 'template_map' => [ + 'layout/album' => __DIR__ . '/../view/layout/layout-of-album.phtml', + ], + ], + // … +]; +``` + +The name of the array key must follow the format `layout/{module-name}` and the +value must contain the path to the layout file. The path and the filename can be +freely chosen. diff --git a/docs/book/v3/helpers/advanced-usage.md b/docs/book/v3/helpers/advanced-usage.md new file mode 100644 index 000000000..79bd56500 --- /dev/null +++ b/docs/book/v3/helpers/advanced-usage.md @@ -0,0 +1,276 @@ +# Advanced usage of helpers + +## Registering Helpers + +`Laminas\View\Renderer\PhpRenderer` composes a *plugin manager* for managing +helpers, specifically an instance of `Laminas\View\HelperPluginManager`, which +extends `Laminas\ServiceManager\AbstractPluginManager`, which is itself an +extension of `Laminas\ServiceManager\ServiceManager`. `HelperPluginManager` is a +specialized service manager, so you can register a helper/plugin like any other +service (see the [Service Manager documentation](https://docs.laminas.dev/laminas-servicemanager/configuring-the-service-manager/) +for more information). + +Programmatically, this is done as follows: + +```php +use MyModule\View\Helper\LowerCase; + +// $view is an instance of PhpRenderer +$pluginManager = $view->getHelperPluginManager(); + +// Register an alias: +$pluginManager->setAlias('lowercase', LowerCase::class); + +// Register a factory: +$pluginManager->setFactory(LowerCase::class, function () { + $lowercaseHelper = new LowerCase(); + + // ...do some configuration or dependency injection... + + return $lowercaseHelper; +}); +``` + +Within an MVC application, you will typically pass a map of plugins to the class +via your configuration. + +```php +use MyModule\View\Helper; +use Laminas\ServiceManager\Factory\InvokableFactory; + +// From within a configuration file +return [ + 'view_helpers' => [ + 'aliases' => [ + 'lowercase' => Helper\LowerCase::class, + 'uppercase' => Helper\UpperCase::class, + ], + 'factories' => [ + LowerCase::class => InvokableFactory::class, + UpperCase::class => InvokableFactory::class, + ], + ], +]; +``` + +If your module class implements `Laminas\ModuleManager\Feature\ViewHelperProviderInterface`, +or just the method `getViewHelperConfig()`, you could also do the following +(it's the same as the previous example). + +```php +namespace MyModule; + +class Module +{ + public function getViewHelperConfig() + { + return [ + 'aliases' => [ + 'lowercase' => Helper\LowerCase::class, + 'uppercase' => Helper\UpperCase::class, + ], + 'factories' => [ + LowerCase::class => InvokableFactory::class, + UpperCase::class => InvokableFactory::class, + ], + ]; + } +} +``` + +The two latter examples can be done in each module that needs to register +helpers with the `PhpRenderer`; however, be aware that another module can +register helpers with the same name, so order of modules can impact which helper +class will actually be registered! + +## Writing Custom Helpers + +Writing custom helpers is easy. We recommend extending +`Laminas\View\Helper\AbstractHelper`, but at the minimum, you need only implement +the `Laminas\View\Helper\HelperInterface` interface: + +```php +namespace Laminas\View\Helper; + +use Laminas\View\Renderer\RendererInterface as Renderer; + +interface HelperInterface +{ + /** + * Set the View object + * + * @param Renderer $view + * @return HelperInterface + */ + public function setView(Renderer $view); + + /** + * Get the View object + * + * @return Renderer + */ + public function getView(); +} +``` + +If you want your helper to be capable of being invoked as if it were a method call of the +`PhpRenderer`, you should also implement an `__invoke()` method within your helper. + +As previously noted, we recommend extending `Laminas\View\Helper\AbstractHelper`, as it implements the +methods defined in `HelperInterface`, giving you a headstart in your development. + +> ### Invokable helpers +> +> Starting with version 2.7.0, helpers no longer need to be instances of +> `HelperInterface`, but can be *any* PHP callable. We recommend writing helpers +> as invokable classes (classes implementing `__invoke()`. + +Once you have defined your helper class, make sure you can autoload it, and then +register it with the [plugin manager](#registering-helpers). + +Here is an example helper, which we're titling "SpecialPurpose" + +```php +namespace MyModule\View\Helper; + +use Laminas\View\Helper\AbstractHelper; + +class SpecialPurpose extends AbstractHelper +{ + protected $count = 0; + + public function __invoke() + { + $this->count++; + $output = sprintf("I have seen 'The Jerk' %d time(s).", $this->count); + return htmlspecialchars($output, ENT_QUOTES, 'UTF-8'); + } +} +``` + +Then assume that we [register it with the plugin manager](#registering-helpers) +by the name "specialPurpose". + +Within a view script, you can call the `SpecialPurpose` helper as many times as +you like; it will be instantiated once, and then it persists for the life of +that `PhpRenderer` instance. + +```php +// remember, in a view script, $this refers to the Laminas\View\Renderer\PhpRenderer instance. +echo $this->specialPurpose(); +echo $this->specialPurpose(); +echo $this->specialPurpose(); +``` + +The output would look something like this: + +```php +I have seen 'The Jerk' 1 time(s). +I have seen 'The Jerk' 2 time(s). +I have seen 'The Jerk' 3 time(s). +``` + +Sometimes you will need access to the calling `PhpRenderer` object; for +instance, if you need to use the registered encoding, or want to render another +view script as part of your helper. This is why we define the `setView()` and +`getView()` methods. As an example, we could rewrite the `SpecialPurpose` helper +as follows to take advantage of the `EscapeHtml` helper: + +```php +namespace MyModule\View\Helper; + +use Laminas\View\Helper\AbstractHelper; + +class SpecialPurpose extends AbstractHelper +{ + protected $count = 0; + + public function __invoke() + { + $this->count++; + $output = sprintf("I have seen 'The Jerk' %d time(s).", $this->count); + $escaper = $this->getView()->plugin('escapehtml'); + return $escaper($output); + } +} +``` + +> ### Accessing the view or other helpers in callables +> +> As noted earlier, starting in version 2.7.0, you may use any PHP callable as a +> helper. If you do, however, how can you access the renderer or other plugins? +> +> The answer is: dependency injection. +> +> If you write your helper as a class, you can accept dependencies via the +> constructor or other setter methods. Create a factory that pulls those +> dependencies and injects them. +> +> As an example, if we need the `escapeHtml()` helper, we could write our helper +> as follows: +> +> ```php +> namespace MyModule\View\Helper; +> +> use Laminas\View\Helper\EscapeHtml; +> +> class SpecialPurpose +> { +> private $count = 0; +> +> private $escaper; +> +> public function __construct(EscapeHtml $escaper) +> { +> $this->escaper = $escaper; +> } +> +> public function __invoke() +> { +> $this->count++; +> $output = sprintf("I have seen 'The Jerk' %d time(s).", $this->count); +> $escaper = $this->escaper; +> return $escaper($output); +> } +> } +> ``` +> +> Then we would write a factory like the following: +> +> ```php +> use Laminas\ServiceManager\AbstractPluginManager; +> +> class SpecialPurposeFactory +> { +> public function __invoke($container) +> { +> if (! $container instanceof AbstractPluginManager) { +> // laminas-servicemanager v3. v2 passes the helper manager directly. +> $container = $container->get('ViewHelperManager'); +> } +> +> return new SpecialPurpose($container->get('escapeHtml')); +> } +> } +> ``` +> +> If access to the view were required, we'd pass the `PhpRenderer` service +> instead. + +## Registering Concrete Helpers + +Sometimes it is convenient to instantiate a view helper, and then register it +with the renderer. This can be done by injecting it directly into the plugin +manager. + +```php +// $view is a PhpRenderer instance + +$helper = new MyModule\View\Helper\LowerCase; +// ...do some configuration or dependency injection... + +$view->getHelperPluginManager()->setService('lowercase', $helper); +``` + +The plugin manager will validate the helper/plugin, and if the validation +passes, the helper/plugin will be registered. diff --git a/docs/book/v3/helpers/asset.md b/docs/book/v3/helpers/asset.md new file mode 100644 index 000000000..2f69e0417 --- /dev/null +++ b/docs/book/v3/helpers/asset.md @@ -0,0 +1,78 @@ +# Asset + +The `Asset` helper is used to map asset names to versioned assets. + +This can be used to allow using a single, canonical name for an asset within +your view scripts, while having that map to: + +- A versioned asset name, used to prevent browser caching. +- A product of a build process (such as a CSS pre-processor, JS compiler, etc.) + +## Configuration and Basic Usage + +`Laminas\View\Helper\Service\AssetFactory` checks the application configuration, +making it possible to set up the resource map through your `module.config.php` +or application configuration. As an example: + +```php +'view_helper_config' => [ + 'asset' => [ + 'resource_map' => [ + 'css/style.css' => 'css/style-3a97ff4ee3.css', + 'js/vendor.js' => 'js/vendor-a507086eba.js', + ], + ], +], +``` + +Within your view script, you would reference the asset name: + +```php +// Usable in any of your .phtml files: +echo $this->asset('css/style.css'); +``` + +which then emits the following output: + +```html +css/style-3a97ff4ee3.css +``` + +The first argument of the `asset` helper is the regular asset name, which will +be replaced by the associated value defined in the `resource_map` of the +configuration. + +> ### Exceptions +> +> When an `asset` key is specified but the `resource_map` is not provided or is not +> an array, the helper will raise a `Laminas\View\Exception\RuntimeException`. +> +> When you call the `asset` helper with a parameter not defined in your +> `resource_map`, the helper will raise a `Laminas\View\Exception\InvalidArgumentException`. + +## Resource map in JSON file + +A number of build tools, such as gulp-rev and grunt-rev, will create a JSON +resource map file such as `rev-manifest.json`: + +```javascript +{ + "css/style.css": "css/style-3a97ff4ee3.css", + "js/vendor.js": "js/vendor-a507086eba.js" +} +``` + +You can incorporate these into your configuration manually by fetching and +decoding the contents: + +```php +'view_helper_config' => [ + 'asset' => [ + 'resource_map' => json_decode(file_get_contents('path/to/rev-manifest.json'), true), + ], +], +``` + +If you have enabled configuration caching, these values _will also be cached_, +meaning that the above operation will occur exactly once in your production +configuration. diff --git a/docs/book/v3/helpers/base-path.md b/docs/book/v3/helpers/base-path.md new file mode 100644 index 000000000..295e50aeb --- /dev/null +++ b/docs/book/v3/helpers/base-path.md @@ -0,0 +1,37 @@ +# BasePath + +While most URLs generated by the framework have the base URL prepended +automatically, developers will need to prepend the base URL to their own URLs +(usually inside an `href` attribute) in order for paths to resources to be +correct. + +If you're running a laminas-mvc application, `basePath()` will point to the +`public` folder of the application's root. + +## Basic Usage + +```php +/* + * The following assume that the base URL of the page/application is "/mypage". + */ + +/* + * Prints: + * + */ + + +/* + * Prints: + * + */ + +``` + +> ### index.php script +> +> For simplicity's sake, we strip out the entry PHP file (e.g., `index.php`) +> from the base URL. However, in some situations this may cause a problem. If +> one occurs, use `$this->plugin('basePath')->setBasePath()` to manually set the +> base path. diff --git a/docs/book/v3/helpers/cycle.md b/docs/book/v3/helpers/cycle.md new file mode 100644 index 000000000..fb2fdd082 --- /dev/null +++ b/docs/book/v3/helpers/cycle.md @@ -0,0 +1,103 @@ +# Cycle + +The `Cycle` helper is used to alternate a set of values. + +## Basic Usage + +To add elements to cycle, specify them in constructor: + +```php + + books as $book): ?> + + + + +
    escapeHtml($book['author']) ?>
    +``` + +The output: + +```php + + + + + + + +
    First
    Second
    +``` + +Instead of passing the data at invocation, you can assign it ahead of time: + +```php +cycle()->assign(['odd', 'even']); ?> +``` + +You can also cycle in reverse, using the `prev()` method instead of `next()`: + +```php + + books as $book): ?> + + + + +
    escapeHtml($book['author']) ?>
    +``` + +The output of the two previous examples combined becomes: + +```php + + + + + + + +
    First
    Second
    +``` + +## Working with two or more cycles + +If you are nesting cycles, you must provide all but one of them with a name; do +this by providing a second parameter to the `cycle()` invocation: +`$this->cycle(['odd', 'even'], 'cycle2')` + +```php + + books as $book): ?> + + + + + +
    cycle([1, 2, 3], 'number')->next() ?>escapeHtml($book['author']) ?>
    +``` + +You can also provide a `$name` argument to `assign()`: + +```php +cycle()->assign([1, 2, 3], 'number'); ?> +``` + +Or use the `setName()` method priort to invoking either of `next()` or `prev()`. + +As a combined example: + +```php +cycle()->assign(['odd', 'even'], 'classes'); +$this->cycle()->assign([1, 2, 3], 'numbers'); +?> + + books as $book): ?> + + + + + +
    cycle()->setName('numbers')->next() ?>escapeHtml($book['author']) ?>
    +``` diff --git a/docs/book/v3/helpers/doctype.md b/docs/book/v3/helpers/doctype.md new file mode 100644 index 000000000..f658add37 --- /dev/null +++ b/docs/book/v3/helpers/doctype.md @@ -0,0 +1,150 @@ +# Doctype + +Valid HTML and XHTML documents should include a `DOCTYPE` declaration. Besides being difficult +to remember, these can also affect how certain elements in your document should be rendered (for +instance, `CDATA` escaping in `'); +} +CSS; + +echo $this->escapeCss($css); +``` + +Output: + +```css +body\20 \7B \D \A \20 \20 \20 \20 background\2D image\3A \20 url\28 \27 http\3A \2F \2F example\2E com\2F foo\2E jpg\3F \3C \2F style\3E \3C script\3E alert\28 1\29 \3C \2F script\3E \27 \29 \3B \D \A \7D +``` + +## EscapeHtml + +```php +$html = ""; + +echo $this->escapeHtml($html); +``` + +Output: + +```html +<script>alert('laminas-framework')</script> +``` + +## EscapeHtmlAttr + +```php+html + + +escapeHtmlAttr($html) ?>>click +``` + +Output: + +```html +click +``` + +## EscapeJs + +```php +$js = "window.location = 'https://getlaminas.org/?cookie=' + document.cookie"; + +echo $this->escapeJs($js); +``` + +Output: + +```js +window.location\x20\x3D\x20\x27https\x3A\x2F\x2Fgetlaminas.org\x2F\x3Fcookie\x3D\x27\x20\x2B\x20document.cookie +``` + +## EscapeUrl + +```php + + +click +``` + +Output: + +```html +click +``` + +## Using Encoding + +```php +$this->escapeHtml()->setEncoding('iso-8859-15'); +``` + +All allowed encodings can be found in the +[documentation of laminas-escaper](https://docs.laminas.dev/laminas-escaper/configuration/). + +### Get Current Value + +To get the current value of this option, use the `getEncoding()` method. + +```php +$this->escapeHtml()->setEncoding('iso-8859-15'); + +echo $this->escapeHtml()->getEncoding(); // iso-8859-15 +``` + +### Default Value + +The default value for all escape helpers is `utf-8`. + +## Using Recursion + +All escape helpers can use recursion for the given values during the escape +operation. This allows the escaping of the datatypes `array` and `object`. + +### Escape an Array + +To escape an `array`, the second parameter `$recurse` must be use the constant +`RECURSE_ARRAY` of an escape helper: + +```php +$html = [ + 'headline' => '

    Foo

    ', + 'content' => [ + 'paragraph' => '

    Bar

    ', + ], +]; + +var_dump($this->escapeHtml($html, Laminas\View\Helper\EscapeHtml::RECURSE_ARRAY)); +``` + +Output: + +```php +array(2) { + 'headline' => + string(24) "<h1>Foo</h1>" + 'content' => + array(1) { + 'paragraph' => + string(22) "<p>Bar</p>" + } +} +``` + +### Escape an Object + +An escape helper can use the `__toString()` method of an object. No additional +parameter is needed: + +```php +$object = new class { + public function __toString() : string + { + return '

    Foo

    '; + } +}; + +echo $this->escapeHtml($object); // "<h1>Foo</h1>" +``` + +An escape helper can also use the `toArray()` method of an object. The second +parameter `$recurse` must be use the constant `RECURSE_OBJECT` of an escape +helper: + +```php +$object = new class { + public function toArray() : array + { + return ['headline' => '

    Foo

    ']; + } +}; + +var_dump($this->escapeHtml($object, Laminas\View\Helper\EscapeHtml::RECURSE_OBJECT)); +``` + +Output: + +```php +array(1) { + 'headline' => + string(3) "<h1>Foo</h1>" +} +``` + +If the object does not contains the methods `__toString()` or `toArray()` then +the object is casted to an `array`: + +```php +$object = new class { + public $headline = '

    Foo

    '; +}; + +var_dump($this->escapeHtml($object, Laminas\View\Helper\EscapeHtml::RECURSE_OBJECT)); +``` + +Output: + +```php +array(1) { + 'headline' => + string(3) "<h1>Foo</h1>" +} +``` + +## Using Custom Escaper + +Create an own instance of `Laminas\Escaper\Escaper` and set to any of the escape +helpers: + +```php +$escaper = new Laminas\Escaper\Escaper('utf-8'); + +$this->escapeHtml()->setEscaper($escaper); +``` + +### Get Current Value + +To get the current value, use the `getEscaper()` method. + +```php +escapeHtml()->setEscaper($escaper); + +var_dump($this->escapeHtml()->getEscaper()); // instance of Laminas\Escaper\Escaper +``` + +### Default Value + +The default value is an instance of `Laminas\Escaper\Escaper`, created by the +helper. diff --git a/docs/book/v3/helpers/gravatar-image.md b/docs/book/v3/helpers/gravatar-image.md new file mode 100644 index 000000000..79aab0a24 --- /dev/null +++ b/docs/book/v3/helpers/gravatar-image.md @@ -0,0 +1,90 @@ +# GravatarImage + +The `GravatarImage` helper is useful for rendering image HTML markup returned from +the [gravatar.com](https://gravatar.com) service. + +## Basic Usage + +You can use the `GravatarImage` helper anywhere in view scripts per the following example: + +```php +echo $this->gravatarImage('email@example.com'); +``` + +The first argument passed to the helper should be an e-mail address for which you want grab an avatar from gravatar.com. For convenience, this e-mail will be automatically hashed via the md5 algorithm. + +This will render an HTML img tag similar to the following: + +```html + +``` + +## Custom Settings + +You can customize the request and HTML output for a gravatar.com image by passing additional arguments to the view helper: + +### Set Image Size + +Provide a positive integer value to the second argument to yield an image with the given dimensions: + +```php +echo $this->gravatarImage('email@example.com', 120); +``` + +Output: + +```html + +``` + +### Set arbitrary image attributes + +You can provide attributes for the resulting image tag as an associative array, but bear in mind that `src`, `width` and `height` attributes will be ignored. + +```php +echo $this->gravatarImage('email@example.com', 120, [ + 'alt' => 'Profile Picture for Someone', + 'data-something' => 'other-thing', +]); +``` + +Output: + +```html +Profile Picture for Someone +``` + +### Change the fallback image + +The Gravatar service will present a default image when a given email address does not correspond to a known profile picture. The possible values are listed in `GravatarImage::DEFAULT_IMAGE_VALUES` and [documented here](https://en.gravatar.com/site/implement/images/). Each possible value has a constant _(Prefixed `DEFAULT_*`)_ you can refer to when specifying the fallback image type. Provide the value as the 4th argument. + +```php +use Laminas\View\Helper\GravatarImage; + +// Set the default avatar image to use if gravatar.com does not find a match +echo $this->gravatarImage('email@example.com', 120, [], GravatarImage::DEFAULT_RETRO); +``` + +You can also supply your own fallback image as a fully qualified url: + +```php +echo $this->gravatarImage('email@example.com', 120, [], 'https://example.com/default-image.png'); +``` + +### Change the image rating allowed + +The Gravatar service allows users to provide a rating for the images they upload to indicate the type of audience they should be acceptable to. By default, the rating is "G". You can allow potentially explicit profile images by changing the rating to a value as [documented by the Gravatar service](https://en.gravatar.com/site/implement/images/). Again, each of the possible ratings are available as constants defined in the helper _(Prefixed `RATING_*`)_ and can be provided as the 5th argument: + +```php +use Laminas\View\Helper\GravatarImage; + +// Set the avatar "rating" threshold (often used to omit NSFW avatars) +$this->gravatarImage( + 'email@example.com', + 120, + [], + GravatarImage::DEFAULT_MP, + GravatarImage::RATING_PG +); + +``` diff --git a/docs/book/v3/helpers/head-link.md b/docs/book/v3/helpers/head-link.md new file mode 100644 index 000000000..7ef1ea08c --- /dev/null +++ b/docs/book/v3/helpers/head-link.md @@ -0,0 +1,68 @@ +# HeadLink + +The HTML `` element is increasingly used for linking a variety of +resources for your site: stylesheets, feeds, favicons, trackbacks, and more. The +`HeadLink` helper provides a simple interface for creating and aggregating these +elements for later retrieval and output in your layout script. + +The `HeadLink` helper has special methods for adding stylesheet links to its +stack: + +- `appendStylesheet($href, $media = 'screen', $conditionalStylesheet = '', $extras = [])` +- `offsetSetStylesheet($index, $href, $media = 'screen', $conditionalStylesheet = '', $extras = [])` +- `prependStylesheet($href, $media = 'screen', $conditionalStylesheet = '', $extras = [])` +- `setStylesheet($href, $media = 'screen', $conditionalStylesheet = '', $extras = [])` + +The `$media` value defaults to 'screen', but may be any valid media value. +`$conditionalStylesheet` is a string or boolean `false`, and will be used at +rendering time to determine if special comments should be included to prevent +loading of the stylesheet on certain platforms. `$extras` is an array of any +extra values that you want to be added to the tag. + +Additionally, the `HeadLink` helper has special methods for adding 'alternate' +links to its stack: + +- `appendAlternate($href, $type, $title, $extras = [])` +- `offsetSetAlternate($index, $href, $type, $title, $extras = [])` +- `prependAlternate($href, $type, $title, $extras = [])` +- `setAlternate($href, $type, $title, $extras = [])` + +The `headLink()` helper method allows specifying all attributes necessary for a +`` element, and allows you to also specify placement: whether the +new element replaces all others, prepends (top of stack), or appends (end of +stack). + +The `HeadLink` helper is a concrete implementation of the +[Placeholder helper](placeholder.md). + +## Basic Usage + +You may specify a `headLink` at any time. Typically, you will specify global +links in your layout script, and application specific links in your application +view scripts. In your layout script, in the `` section, you will then echo +the helper to output it. + +```php +headLink(['rel' => 'icon', 'href' => '/img/favicon.ico'], 'PREPEND') + ->appendStylesheet('/styles/basic.css') + ->prependStylesheet( + '/styles/moz.css', + 'screen', + true, + ['id' => 'my_stylesheet'] + ); + +// rendering the links from the layout: +echo $this->headLink(); +?> +``` + +Output: + +```html + + + +``` diff --git a/docs/book/v3/helpers/head-meta.md b/docs/book/v3/helpers/head-meta.md new file mode 100644 index 000000000..a07397686 --- /dev/null +++ b/docs/book/v3/helpers/head-meta.md @@ -0,0 +1,158 @@ +# HeadMeta + +The HTML `` element is used to provide meta information about your HTML +document, typically keywords, document character set, caching pragmas, etc. Meta +tags may be either of the `http-equiv` or `name` types, must contain a `content` +attribute, and can also have either of the `lang` or `scheme` modifier +attributes. + +The `HeadMeta` helper supports the following methods for setting and adding meta tags: + +- `appendName($keyValue, $content, $conditionalName)` +- `offsetSetName($index, $keyValue, $content, $conditionalName)` +- `prependName($keyValue, $content, $conditionalName)` +- `setName($keyValue, $content, $modifiers)` +- `appendHttpEquiv($keyValue, $content, $conditionalHttpEquiv)` +- `offsetSetHttpEquiv($index, $keyValue, $content, $conditionalHttpEquiv)` +- `prependHttpEquiv($keyValue, $content, $conditionalHttpEquiv)` +- `setHttpEquiv($keyValue, $content, $modifiers)` +- `setCharset($charset)` + +The following methods are also supported with `XHTML1_RDFA` doctype set with the +[Doctype helper](doctype.md). + +- `appendProperty($property, $content, $modifiers)` +- `offsetSetProperty($index, $property, $content, $modifiers)` +- `prependProperty($property, $content, $modifiers)` +- `setProperty($property, $content, $modifiers)` + +Finally, starting in 2.11.2, you can call the following method to determine +whether or not to autoescape values used in meta tags: + +- `setAutoEscape(bool $autoEscape = true)` (enabled by default) + + +> ### AutoEscape +> +> **Disable this flag at your own risk.** The one documented case where it is +> necessary to disable the flag is when setting the `X-UA-Compatible` +> `http-equiv` value to switch behavior for Internet Explorer, as escaped values +> will not trigger correct representation. + +The `$keyValue` item is used to define a value for the `name` or `http-equiv` +key; `$content` is the value for the 'content' key, and `$modifiers` is an +optional associative array that can contain keys for `lang` and/or `scheme`. + +You may also set meta tags using the `headMeta()` helper method, which has the +following signature: `headMeta($content, $keyValue, $keyType = 'name', +$modifiers = [], $placement = 'APPEND')`. `$keyValue` is the content for +the key specified in `$keyType`, which should be either `name` or `http-equiv`. +`$keyType` may also be specified as `property` if the doctype has been set to +`XHTML1_RDFA`. `$placement` can be `SET` (overwrites all previously stored +values), `APPEND` (added to end of stack), or `PREPEND` (added to top of stack). + +`HeadMeta` overrides each of `append()`, `offsetSet()`, `prepend()`, and `set()` +to enforce usage of the special methods as listed above. Internally, it stores +each item as a `stdClass` token, which it later serializes using the +`itemToString()` method. This allows you to perform checks on the items in the +stack, and optionally modify these items by simply modifying the object +returned. + +The `HeadMeta` helper is a concrete implementation of the +[Placeholder helper](placeholder.md). + +## Basic Usage + +You may specify a new meta tag at any time. Typically, you will specify +client-side caching rules or SEO keywords. + +For instance, if you wish to specify SEO keywords, you'd be creating a meta name +tag with the name `keywords` and the content the keywords you wish to associate +with your page: + +```php +// setting meta keywords +$this->headMeta()->appendName('keywords', 'framework, PHP, productivity'); +``` + +If you wished to set some client-side caching rules, you'd set `http-equiv` tags +with the rules you wish to enforce: + +```php +// disabling client-side cache +$this->headMeta() + ->appendHttpEquiv('expires', 'Wed, 26 Feb 1997 08:21:57 GMT') + ->appendHttpEquiv('pragma', 'no-cache') + ->appendHttpEquiv('Cache-Control', 'no-cache'); +``` + +Another popular use for meta tags is setting the content type, character set, +and language: + +```php +// setting content type and character set +$this->headMeta() + ->appendHttpEquiv('Content-Type', 'text/html; charset=UTF-8') + ->appendHttpEquiv('Content-Language', 'en-US'); +``` + +If you are serving an HTML5 document, you should provide the character set like +this: + +```php +// setting character set in HTML5 +$this->headMeta()->setCharset('UTF-8'); // Will look like +``` + +As a final example, an easy way to display a transitional message before a +redirect is using a "meta refresh": + +```php +// setting a meta refresh for 3 seconds to a new url: +$this->headMeta() + ->appendHttpEquiv('Refresh', '3;URL=http://www.some.org/some.html'); +``` + +When you're ready to place your meta tags in the layout, echo the helper: + +```php +headMeta() ?> +``` + +## Usage with XHTML1\_RDFA doctype + +Enabling the RDFa doctype with the [Doctype helper](doctype.md) enables the use +of the `property` attribute (in addition to the standard `name` and +`http-equiv`) with `HeadMeta`. This is commonly used with the Facebook [Open +Graph Protocol](http://opengraphprotocol.org/). + +For instance, you may specify an open graph page title and type as follows: + +```php +$this->doctype(Laminas\View\Helper\Doctype::XHTML1_RDFA); +$this->headMeta()->setProperty('og:title', 'my article title'); +$this->headMeta()->setProperty('og:type', 'article'); +echo $this->headMeta(); + +// output is: +// +// +``` + +## Usage with HTML5 doctype + +Enabling the HTML5 doctype with the [Doctype helper](doctype.md) enables the use +of the `itemprop` attribute (in addition to the standard `name` and +`http-equiv`) with `HeadMeta`. This is typically used to add +[Microdata](https://schema.org) to the head of your document. + +```php +$this->doctype(Laminas\View\Helper\Doctype::HTML5); +$this->headMeta()->setItemprop('headline', 'My Article Headline'); +$this->headMeta()->setItemprop('dateCreated', $date->format('c')); +echo $this->headMeta(); + +// output is: +// +// +``` diff --git a/docs/book/v3/helpers/head-script.md b/docs/book/v3/helpers/head-script.md new file mode 100644 index 000000000..f257a1b47 --- /dev/null +++ b/docs/book/v3/helpers/head-script.md @@ -0,0 +1,159 @@ +# HeadScript + +The HTML ` + + +``` + +## Capturing Scripts + +Add in your view scripts: + +```php +$this->inlineScript()->captureStart(); +echo <<inlineScript()->captureEnd(); +``` + +Output: + +```html + + + + + + + +``` diff --git a/docs/book/v3/helpers/intro.md b/docs/book/v3/helpers/intro.md new file mode 100644 index 000000000..1aa4a08f1 --- /dev/null +++ b/docs/book/v3/helpers/intro.md @@ -0,0 +1,121 @@ +# Introduction + +In your view scripts, you'll perform certain complex functions over and over: +e.g., formatting a date, generating form elements, or displaying action links. +You can use helper, or plugin, classes to perform these behaviors for you. + +A helper is a class that implements `Laminas\View\Helper\HelperInterface`, which +defines two methods, `setView()`, which accepts a +`Laminas\View\Renderer\RendererInterface` instance/implementation, and `getView()`, +used to retrieve that instance. `Laminas\View\Renderer\PhpRenderer` composes a +*plugin manager*, allowing you to retrieve helpers, and also provides some +method overloading capabilities that allow proxying method calls to helpers. + + +> ### Callable Helpers +> +> Starting in version 2.7.0, if your helper does not need access to the view, +> you can also use any PHP callable as a helper, including arbitrary objects +> that implement `__invoke()`. + +As an example, let's say we have a helper class named +`MyModule\View\Helper\LowerCase`, which we register in our plugin manager with +the name `lowercase`. We can retrieve it in one of the following ways: + +```php +// $view is a PhpRenderer instance + +// Via the plugin manager: +$pluginManager = $view->getHelperPluginManager(); +$helper = $pluginManager->get('lowercase'); + +// Retrieve the helper instance, via the method "plugin", +// which proxies to the plugin manager: +$helper = $view->plugin('lowercase'); + +// If the helper does not define __invoke(), the following also retrieves it: +$helper = $view->lowercase(); + +// If the helper DOES define __invoke, you can call the helper +// as if it is a method: +$filtered = $view->lowercase('some value'); +``` + +The last two examples demonstrate how the `PhpRenderer` uses method overloading +to retrieve and/or invoke helpers directly, offering a convenience API for end +users. + +A large number of helpers are provided by default with laminas-view. You can also +register helpers by adding them to the plugin manager. + +## Included Helpers + +Laminas comes with an initial set of helper classes. In particular, there +are helpers for creating route-based URLs and HTML lists, as well as declaring +variables. Additionally, there are a rich set of helpers for providing values +for, and rendering, the various HTML `` tags, such as `HeadTitle`, +`HeadLink`, and `HeadScript`. The currently shipped helpers include: + +- [Asset](asset.md) +- [BasePath](base-path.md) +- [Cycle](cycle.md) +- [Doctype](doctype.md) +- [Gravatar](gravatar.md) *(Deprecated)* +- [GravatarImage](gravatar-image.md) +- [HeadLink](head-link.md) +- [HeadMeta](head-meta.md) +- [HeadScript](head-script.md) +- [HeadStyle](head-style.md) +- [HeadTitle](head-title.md) +- [HtmlList](html-list.md) +- [HTML Object Plugins](html-object.md) +- [HtmlTag](html-tag.md) +- [Identity](identity.md) +- [InlineScript](inline-script.md) +- [JSON](json.md) +- [Layout](layout.md) +- [Partial](partial.md) +- [Placeholder](placeholder.md) +- [Url](url.md) + +> ### Help Us Document the Helpers +> +> Not all helpers are documented! Some that could use documentation include the +> various escaper helpers, the layout helper, and the `serverUrl` helper. Click +> the "GitHub" octocat link in the top navbar to go to the repository and start +> writing documentation! + +> ### i18n Helpers +> +> View helpers related to **Internationalization** are documented in the +> [I18n View Helpers](https://docs.laminas.dev/laminas-i18n/view-helpers/) +> documentation. + +> ### Form Helpers +> +> View helpers related to **form** are documented in the +> [Form View Helpers](https://docs.laminas.dev/laminas-form/helper/intro/) +> documentation. + +> ### Navigation Helpers +> +> View helpers related to **navigation** are documented in the +> [Navigation View Helpers](https://docs.laminas.dev/laminas-navigation/helpers/intro/) +> documentation. + +> ### Pagination Helpers +> +> View helpers related to **paginator** are documented in the +> [Paginator Usage](https://docs.laminas.dev/laminas-paginator/usage/#rendering-pages-with-view-scripts) +> documentation. + +> ### FlashMessenger helper +> +> View helper related to **Flash Messenger** is documented in the +> [FLash Messenger View Helper](https://docs.laminas.dev/laminas-mvc-plugin-flashmessenger/view-helper/) +> documentation. + +> ### Custom Helpers +> +> For documentation on writing **custom view helpers** see the +> [Advanced usage](advanced-usage.md) chapter. diff --git a/docs/book/v3/helpers/json.md b/docs/book/v3/helpers/json.md new file mode 100644 index 000000000..655a9f788 --- /dev/null +++ b/docs/book/v3/helpers/json.md @@ -0,0 +1,21 @@ +# Json + +When creating views that return JSON, it's important to also set the appropriate +response header. The JSON view helper does exactly that. In addition, by +default, it disables layouts (if currently enabled), as layouts generally aren't +used with JSON responses. + +The JSON helper sets the following header: + +```http +Content-Type: application/json +``` + +Most XmlHttpRequest libraries look for this header when parsing responses to +determine how to handle the content. + +## Basic Usage + +```php +json($this->data) ?> +``` diff --git a/docs/book/v3/helpers/layout.md b/docs/book/v3/helpers/layout.md new file mode 100644 index 000000000..48f393227 --- /dev/null +++ b/docs/book/v3/helpers/layout.md @@ -0,0 +1,60 @@ +# Layout + +The `Layout` helper is used to get and set the template for the layout or to +retrieving the root view model. + +## Basic Usage + +### Change the Layout Template + +If you're running a laminas-mvc application then the layout template is set in the +configuration for the [`ViewManager`](https://docs.laminas.dev/laminas-mvc/services/#viewmanager). + +To change the layout template within a view script, call: + +```php +$this->layout('layout/backend'); +``` + +Or use the `setTemplate` method: + +```php +$this->layout()->setTemplate('layout/backend'); +``` + +### Set View Variable on Layout Model + +The `Layout` helper can also retrieve the view model for the layout (root): + +```php +/** @var \Laminas\View\Model\ViewModel $rootViewModel */ +$rootViewModel = $this->layout(); +``` + +This offers the possibility to set variables for the layout script. + +#### Set a Single Variable + +```php +$this->layout()->setVariable('infoText', 'Some text for later'); +``` + +Use in your layout script: + +```php +if (isset($infoText)) { + echo $infoText; +} +``` + +#### Set a Set of Variables + +```php +$this->layout()->setVariables([ + 'headerText' => '…', + 'footerText' => '…', +]); +``` + +More information related to view models can be found in the +[quick start](https://docs.laminas.dev/laminas-view/quick-start/). diff --git a/docs/book/v3/helpers/partial.md b/docs/book/v3/helpers/partial.md new file mode 100644 index 000000000..99ab87a6b --- /dev/null +++ b/docs/book/v3/helpers/partial.md @@ -0,0 +1,134 @@ +# Partial + +The `Partial` view helper is used to render a specified template within its own +variable scope. The primary use is for reusable template fragments with which +you do not need to worry about variable name clashes. + +A sibling to the `Partial`, the `PartialLoop` view helper allows you to pass +iterable data, and render a partial for each item. + + +> ### PartialLoop Counter +> +> The `PartialLoop` view helper gives access to the current position of the +> array within the view script via `$this->partialLoop()->getPartialCounter()`. +> This provides a way to have alternating colors on table rows, for example. + +## Basic Usage + +Basic usage of partials is to render a template fragment in its own view scope. +Consider the following partial script: + +```php + +
      +
    • From: escapeHtml($this->from) ?>
    • +
    • Subject: escapeHtml($this->subject) ?>
    • +
    +``` + +You would then call it from your view script using the following: + +```php +partial('partial.phtml', [ + 'from' => 'Team Framework', + 'subject' => 'view partials', +]); ?> +``` + +Which would then render: + +```html +
      +
    • From: Team Framework
    • +
    • Subject: view partials
    • +
    +``` + +> ### What is a model? +> +> A model used with the `Partial` view helper can be one of the following: +> +> - **`array`**: If an array is passed, it should be associative, as its key/value +> pairs are assigned to > the view with keys as view variables. +> - **Object implementing `toArray(`) method**. If an object is passed an has a +> `toArray()` method, the results of `toArray()` will be assigned to the view +> object as view variables. +> - **Standard object**. Any other object will assign the results of +> `get_object_vars()` (essentially all public properties of the object) to the +> view object. +> +> If your model is an object, you may want to have it passed **as an object** to +> the partial script, instead of serializing it to an array of variables. You +> can do this by setting the `objectKey` property of the appropriate helper: +> +> ```php +> // Tell partial to pass objects as 'model' variable +> $view->partial()->setObjectKey('model'); +> +> // Tell partial to pass objects from partialLoop as 'model' variable +> // in final partial view script: +> $view->partialLoop()->setObjectKey('model'); +> ``` +> +> This technique is particularly useful when passing +> `Laminas\Db\ResultSet\ResultSet`s to `partialLoop()`, as you then have full +> access to your row objects within the view scripts, allowing you to call +> methods on them (such as retrieving values from parent or dependent rows). + +## Using PartialLoop to Render Iterable Models + +Typically, you'll want to use partials in a loop, to render the same content +fragment many times; this way you can put large blocks of repeated content or +complex display logic into a single location. However this has a performance +impact, as the partial helper needs to be invoked once for each iteration. + +The `PartialLoop` view helper helps solve this issue. It allows you to pass an +iterable item (array or object implementing `Iterator`) as the model. It then +iterates over this, passing, the items to the partial script as the model. Items +in the iterator may be any model the `Partial` view helper allows. + +Let's assume the following partial view script: + +```php + +
    key ?>
    +
    value ?>
    +``` + +And the following "model": + +```php +$model = [ + ['key' => 'Mammal', 'value' => 'Camel'], + ['key' => 'Bird', 'value' => 'Penguin'], + ['key' => 'Reptile', 'value' => 'Asp'], + ['key' => 'Fish', 'value' => 'Flounder'], +]; +``` + +In your view script, you could then invoke the `PartialLoop` helper: + +```php +
    +partialLoop('partialLoop.phtml', $model) ?> +
    +``` + +Resulting in the following: + +```html +
    +
    Mammal
    +
    Camel
    + +
    Bird
    +
    Penguin
    + +
    Reptile
    +
    Asp
    + +
    Fish
    +
    Flounder
    +
    +``` diff --git a/docs/book/v3/helpers/placeholder.md b/docs/book/v3/helpers/placeholder.md new file mode 100644 index 000000000..e8013554f --- /dev/null +++ b/docs/book/v3/helpers/placeholder.md @@ -0,0 +1,171 @@ +# Placeholder + +The `Placeholder` view helper is used to persist content between view scripts +and view instances. It also offers some useful features such as aggregating +content, capturing view script content for later use, and adding pre- and +post-text to content (and custom separators for aggregated content). + +## Basic Usage + +Basic usage of placeholders is to persist view data. Each invocation of the +`Placeholder` helper expects a placeholder name; the helper then returns a +placeholder container object that you can either manipulate or echo. + +```php +placeholder('foo')->set("Some text for later") ?> + +placeholder('foo'); ?> +``` + +Results in: + +```html +Some text for later +``` + +## Aggregate Content + +Aggregating content via placeholders can be useful at times as well. For +instance, your view script may have a variable array from which you wish to +retrieve messages to display later; a later view script can then determine how +those will be rendered. + +The `Placeholder` view helper uses containers that extend `ArrayObject`, +providing a rich feature set for manipulating arrays. In addition, it offers a +variety of methods for formatting the content stored in the container: + +- `setPrefix($prefix)` sets text with which to prefix the content. Use + `getPrefix()` at any time to determine what the current setting is. +- `setPostfix($prefix)` sets text with which to append the content. Use + `getPostfix()` at any time to determine what the current setting is. +- `setSeparator($prefix)` sets text with which to separate aggregated content. + Use `getSeparator()` at any time to determine what the current setting is. +- `setIndent($prefix)` can be used to set an indentation value for content. If + an integer is passed, that number of spaces will be used; if a string is + passed, the string will be used. Use `getIndent()` at any time to determine + what the current setting is. + +Set the data in one view script: + +```php + +placeholder('foo')->exchangeArray($this->data) ?> +``` + +And retrieve the data and output it in another view script: + +```php + +placeholder('foo') + ->setPrefix("
      \n
    • ") + ->setSeparator("
    • \n") + ->setIndent(4) + ->setPostfix("
    \n"); +?> + +placeholder('foo') ?> +``` + +The above results in an unordered list with pretty indentation. + +Because the `Placeholder` container objects extend `ArrayObject`, you can also +assign content to a specific key in the container easily, instead of simply +pushing it into the container. Keys may be accessed either as object properties +or as array keys. + +```php +placeholder('foo')->bar = $this->data ?> +placeholder('foo')->bar ?> + +placeholder('foo'); +echo $foo['bar']; +``` + +## Capture Content + +Occasionally you may have content for a placeholder in a view script that is +easiest to template; the `Placeholder` view helper allows you to capture +arbitrary content for later rendering using the following API. + +- `captureStart($type, $key)` begins capturing content. + - `$type` should be one of the `Placeholder` constants `APPEND` or `SET`. If + `APPEND`, captured content is appended to the list of current content in the + placeholder; if `SET`, captured content is used as the sole value of the + placeholder (potentially replacing any previous content). By default, + `$type` is `APPEND`. + - `$key` can be used to specify a specific key in the placeholder container to + which you want content captured. + - `captureStart()` locks capturing until `captureEnd()` is called; you cannot + nest capturing with the same placeholder container. Doing so will raise an + exception. +- `captureEnd()` stops capturing content, and places it in the container object + according to how `captureStart()` was called. + +As an example: + +```php + +placeholder('foo')->captureStart(); +foreach ($this->data as $datum): ?> +
    +

    title ?>

    +

    content ?>

    +
    + +placeholder('foo')->captureEnd() ?> + +placeholder('foo') ?> +``` + +Alternately, capture to a key: + +```php + +placeholder('foo')->captureStart('SET', 'data'); +foreach ($this->data as $datum): ?> +
    +

    title ?>

    +

    content ?>

    +
    + +placeholder('foo')->captureEnd() ?> + +placeholder('foo')->data ?> +``` + +## Clearing Content + +In certain situations it is desirable to remove or clear containers and +aggregated content. The placeholder view helper provides two methods to either +delete a specific container or clear all containers at once: + +### Delete a single container + +```php +$this->plugin('placeholder')->deleteContainer('myNamedContainer'); +``` + +### Clear all containers + +```php +$this->plugin('placeholder')->clearContainers(); +``` + +## Concrete Implementations + +laminas-view ships with a number of "concrete" placeholder implementations. These +are for commonly used placeholders: doctype, page title, and various `` +elements. In all cases, calling the placeholder with no arguments returns the +element itself. + +Documentation for each element is covered separately, as linked below: + +- [Doctype](doctype.md) +- [HeadLink](head-link.md) +- [HeadMeta](head-meta.md) +- [HeadScript](head-script.md) +- [HeadStyle](head-style.md) +- [HeadTitle](head-title.md) +- [InlineScript](inline-script.md) diff --git a/docs/book/v3/helpers/url.md b/docs/book/v3/helpers/url.md new file mode 100644 index 000000000..1aba2aa0f --- /dev/null +++ b/docs/book/v3/helpers/url.md @@ -0,0 +1,238 @@ +# Url + +The URL view helper is used to create a string representation of the routes that +you define within your application. The syntax for the view helper is +`$this->url($name, $params, $options, $reuseMatchedParameters)`, using the +following definitions for the helper arguments: + +- `$name`: The name of the route you want to output. +- `$params`: An array of parameters that is defined within the respective route + configuration. +- `$options`: An array of options that will be used to create the URL. +- `$reuseMatchedParams`: A flag indicating if the currently matched route + parameters should be used when generating the new URL. + +Let's take a look at how this view helper is used in real-world applications. + +## Basic Usage + +The following example shows a simple configuration for a news module. The route +is called `news` and it has two **optional** parameters called `action` and +`id`. + +```php +// In a configuration array (e.g. returned by some module's module.config.php) +'router' => [ + 'routes' => [ + 'news' => [ + 'type' => 'segment', + 'options' => [ + 'route' => '/news[/:action][/:id]', + 'constraints' => [ + 'action' => '[a-zA-Z][a-zA-Z0-9_-]*', + ], + 'defaults' => [ + 'controller' => 'news', + 'action' => 'index', + ], + ], + ], + ], +], +``` + +First, let's use the view helper to create the output for the URL `/news` without any of the +optional parameters being used: + +```php +News Index +``` + +This will render the output: + +```html +News Index +``` + +Now let's assume we want to get a link to display the detail page of a single +news entry. For this task, the optional parameters `action` and `id` need to +have values assigned. This is how you do that: + +```php + + Details of News #42 + +``` + +This will render the output: + +```html +News Index +``` + +## Query String Arguments + +Most SEO experts agree that pagination parameters should not be part of the URL +path; for example, the following URL would be considered a bad practice: +`/news/archive/page/13`. Pagination is more correctly accomplished using a query +string arguments, such as `/news/archive?page=13`. To achieve this, you'll need +to make use of the `$options` argument from the view helper. + +We will use the same route configuration as defined above: + +```php +// In a configuration array (e.g. returned by some module's module.config.php) +'router' => [ + 'routes' => [ + 'news' => [ + 'type' => 'segment', + 'options' => [ + 'route' => '/news[/:action][/:id]', + 'constraints' => [ + 'action' => '[a-zA-Z][a-zA-Z0-9_-]*', + ], + 'defaults' => [ + 'controller' => 'news', + 'action' => 'index', + ], + ], + ], + ], +], +``` + +To generate query string arguments from the view helper, you need to assign them +as the third argument using the `query` key like this: + +```php +url( + 'news', + ['action' => 'archive'], + [ + 'query' => [ + 'page' => 13, + ], + ] +); +?> +News Archive Page #13 +``` + +The above code sample would output: + +```html +News Archive Page #13 +``` + +## Fragments + +Another possible entry within the `$options` array is the assignment of URL +fragments (typically used to link to in-page anchors), denoted with using the +`fragment` key. Let's assume we want to enter a link for users to directly jump +to the comment section of a details page: + +```php +url( + 'news', + ['action' => 'details', 'id' => 42], + [ + 'fragment' => 'comments', + ] +); +?> +Comment Section of News #42 +``` + +The above code sample would output: + +```html +Comment Section of News #42 +``` + +You can use `fragment` and `query` options at the same time! + +```php +url( + 'news', + ['action' => 'details', 'id' => 42], + [ + 'query' => [ + 'commentPage' => 3, + ], + 'fragment' => 'comments', + ] +); +?> +Comment Section of News #42 +``` + +The above code sample would output: + +```html +Comment Section of News #42 +``` + +## Fully Qualified Domain Name + +Another possible entry within the `$options` array is to output a fully +qualified domain name (absolute URL), denoted using the `force_canonical` key: + +```php +url( + 'news', + [], + [ + 'force_canonical' => true, + ] +); +?> +News Index +``` + +The above code sample would output: + +```html +News Index +``` + +## Reusing Matched Parameters + +When you're on a route that has many parameters, often times it makes sense to +reuse currently matched parameters instead of assigning them explicitly. In this +case, the argument `$reuseMatchedParams` will come in handy. + +As an example, we will imagine being on a detail page for our `news` route. We +want to display links to the `edit` and `delete` actions without having to +assign the ID again: + +```php +// Currently url /news/details/777 + +Edit Me +Delete Me +``` + +Notice the `true` argument in the fourth position. This tells the view helper to +use the matched `id` (`777`) when creating the new URL: + +```html +Edit Me +Edit Me +``` + +### Shorthand + +Due to the fact that reusing parameters is a use case that can happen when no +route options are set, the third argument for the URL view helper will be +checked against its type; when a `boolean` is passed, the helper uses it to set +the value of the `$reuseMatchedParams` flag: + +```php +$this->url('news', ['action' => 'archive'], null, true); +// is equal to +$this->url('news', ['action' => 'archive'], true); +``` diff --git a/docs/book/v3/php-renderer.md b/docs/book/v3/php-renderer.md new file mode 100644 index 000000000..981225f75 --- /dev/null +++ b/docs/book/v3/php-renderer.md @@ -0,0 +1,382 @@ +# The PhpRenderer + +`Laminas\View\Renderer\PhpRenderer` "renders" view scripts written in PHP, +capturing and returning the output. It composes Variable containers and/or View +Models, a helper plugin manager for [helpers](helpers/intro.md), and optional +filtering of the captured output. + +The `PhpRenderer` is template-system agnostic; you may use PHP as your template +language, or create instances of other template systems and manipulate them +within your view script. Anything you can do with PHP is available to you. + +## Usage + +Basic usage consists of instantiating or otherwise obtaining an instance of the +`PhpRenderer`, providing it with a resolver which will resolve templates to PHP +view scripts, and then calling its `render()` method. + +Instantiating a renderer: + +```php +use Laminas\View\Renderer\PhpRenderer; + +$renderer = new PhpRenderer(); +``` + +laminas-view ships with several types of "resolvers", which are used to resolve a +template name to a resource a renderer can consume. The ones we will usually use +with the `PhpRenderer` are: + +- `Laminas\View\Resolver\TemplateMapResolver`, which simply maps template names + directly to view scripts. +- `Laminas\View\Resolver\TemplatePathStack`, which creates a LIFO stack of script + directories in which to search for a view script. By default, it appends the + suffix `.phtml` to the requested template name, and then loops through the + script directories; if it finds a file matching the requested template, it + returns the full file path. +- `Laminas\View\Resolver\RelativeFallbackResolver`, which allows using short + template name into partial rendering. It is used as wrapper for each of two + aforesaid resolvers. For example, this allows usage of partial template paths + such as `my/module/script/path/my-view/some/partial.phtml`, while rendering + template `my/module/script/path/my-view` by short name `some/partial`. +- `Laminas\View\Resolver\AggregateResolver`, which allows attaching a FIFO queue of + resolvers to consult. + +We suggest using the `AggregateResolver`, as it allows you to create a +multi-tiered strategy for resolving template names. + +Programmatically, you would then do something like this: + +```php +use Laminas\View\Renderer\PhpRenderer; +use Laminas\View\Resolver; + +$renderer = new PhpRenderer(); + +$resolver = new Resolver\AggregateResolver(); + +$renderer->setResolver($resolver); + +$map = new Resolver\TemplateMapResolver([ + 'layout' => __DIR__ . '/view/layout.phtml', + 'index/index' => __DIR__ . '/view/index/index.phtml', +]); +$stack = new Resolver\TemplatePathStack([ + 'script_paths' => [ + __DIR__ . '/view', + $someOtherPath + ], +]); + +// Attach resolvers to the aggregate: +$resolver + ->attach($map) // this will be consulted first, and is the fastest lookup + ->attach($stack) // filesystem-based lookup + ->attach(new Resolver\RelativeFallbackResolver($map)) // allow short template names + ->attach(new Resolver\RelativeFallbackResolver($stack)); +``` + +You can also specify a specific priority value when registering resolvers, with +high, positive integers getting higher priority, and low, negative integers +getting low priority, when resolving. + +If you are started your application via the [laminas-mvc-skeleton](https://github.com/laminas/laminas-mvc-skeleton), +you can provide the above via configuration: + +```php +// In the Application module configuration +// (module/Application/config/module.config.php): +return [ + 'view_manager' => [ + 'template_map' => [ + 'layout' => __DIR__ . '/../view/layout.phtml', + 'index/index' => __DIR__ . '/../view/index/index.phtml', + ], + 'template_path_stack' => [ + 'application' => __DIR__ . '/../view', + ], + ], +]; +``` + +If you did not begin with the skeleton application, you will need to write your +own factories for creating each resolver and wiring them to the +`AggregateResolver` and injecting into the `PhpRenderer`. + +Now that we have our `PhpRenderer` instance, and it can find templates, let's +inject some variables. This can be done in 4 different ways. + +- Pass an associative array (or `ArrayAccess` instance, or `Laminas\View\Variables` + instance) of items as the second argument to `render()`: + `$renderer->render($templateName, ['foo' => 'bar'])` +- Assign a `Laminas\View\Variables` instance, associative array, or `ArrayAccess` + instance to the `setVars()` method. +- Assign variables as instance properties of the renderer: `$renderer->foo = + 'bar'`. This essentially proxies to an instance of `Variables` composed + internally in the renderer by default. +- Create a `ViewModel` instance, assign variables to that, and pass the + `ViewModel` to the `render()` method: + +As an example of the latter: + +```php +use Laminas\View\Model\ViewModel; +use Laminas\View\Renderer\PhpRenderer; + +$renderer = new PhpRenderer(); + +$model = new ViewModel(); +$model->setVariable('foo', 'bar'); +// or +$model = new ViewModel(['foo' => 'bar']); + +$model->setTemplate($templateName); +$renderer->render($model); +``` + +Now, let's render something. As an example, let us say you have a list of +book data. + +```php +// use a model to get the data for book authors and titles. +$data = [ + [ + 'author' => 'Hernando de Soto', + 'title' => 'The Mystery of Capitalism', + ], + [ + 'author' => 'Henry Hazlitt', + 'title' => 'Economics in One Lesson', + ], + [ + 'author' => 'Milton Friedman', + 'title' => 'Free to Choose', + ], +]; + +// now assign the book data to a renderer instance +$renderer->books = $data; + +// and render the template "booklist" +echo $renderer->render('booklist'); +``` + +More often than not, you'll likely be using the MVC layer. As such, you should +be thinking in terms of view models. Let's consider the following code from +within an action method of a controller. + +```php +namespace Bookstore\Controller; + +use Laminas\Mvc\Controller\AbstractActionController; + +class BookController extends AbstractActionController +{ + public function listAction() + { + // do some work... + + // Assume $data is the list of books from the previous example + $model = new ViewModel(['books' => $data]); + + // Optionally specify a template; if we don't, by default it will be + // auto-determined based on the module name, controller name and this action. + // In this example, the template would resolve to "bookstore/book/list", + // and thus the file "bookstore/book/list.phtml"; the following overrides + // that to set the template to "booklist", and thus the file "booklist.phtml" + // (note the lack of directory preceding the filename). + $model->setTemplate('booklist'); + + return $model + } +} +``` + +This will then be rendered as if the following were executed: + +```php +$renderer->render($model); +``` + +Now we need the associated view script. At this point, we'll assume that the +template `booklist` resolves to the file `booklist.phtml`. This is a PHP script +like any other, with one exception: it executes inside the scope of the +`PhpRenderer` instance, which means that references to `$this` point to the +`PhpRenderer` instance properties and methods. Thus, a very basic view script +could look like this: + +```php +books): ?> + + + + + + + + + books as $key => $val): ?> + + + + + + +
    AuthorTitle
    escapeHtml($val['author']) ?>escapeHtml($val['title']) ?>
    + + + +

    There are no books to display.

    + + +``` + +> ### Escape Output +> +> The security mantra is "Filter input, escape output." If you are unsure of the +> source of a given variable — which is likely most of the time — +> you should escape it based on which HTML context it is being injected into. +> The primary contexts to be aware of are HTML Body, HTML Attribute, Javascript, +> CSS and URI. Each context has a dedicated helper available to apply the +> escaping strategy most appropriate to each context. You should be aware that +> escaping does vary significantly between contexts; there is no one single +> escaping strategy that can be globally applied. In the example above, there +> are calls to an `escapeHtml()` method. The method is actually +> [a helper](helpers/intro.md), a plugin available via method overloading. +> Additional escape helpers provide the `escapeHtmlAttr()`, `escapeJs()`, +> `escapeCss()`, and `escapeUrl()` methods for each of the HTML contexts you are +> most likely to encounter. By using the provided helpers and being aware of +> your variables' contexts, you will prevent your templates from running afoul +> of [Cross-Site Scripting (XSS)](http://en.wikipedia.org/wiki/Cross-site_scripting) +> vulnerabilities. + +We've now toured the basic usage of the `PhpRenderer`. By now you should know +how to instantiate the renderer, provide it with a resolver, assign variables +and/or create view models, create view scripts, and render view scripts. + +## Options and Configuration + +`Laminas\View\Renderer\PhpRenderer` utilizes several collaborators in order to do +its work. Use the following methods to configure the renderer. + +Unless otherwise noted, class names are relative to the `Laminas\View` namespace. + +### setHelperPluginManager + +```php +setHelperPluginManager(string|HelperPluginManager $helpers): void +``` + +Set the helper plugin manager instance used to load, register, and retrieve +[helpers](helpers/intro.md). + +### setResolver + +```php +setResolver(Resolver\\ResolverInterface $resolver) : void +``` + +Set the resolver instance. + +### setFilterChain + +```php +setFilterChain(\Laminas\Filter\FilterChain $filters) : void +``` + +Set a filter chain to use as an output filter on rendered content. + +### setVars + +```php +setVars(array|\ArrayAccess|Variables $variables) : void +``` + +Set the variables to use when rendering a view script/template. + +### setCanRenderTrees + +```php +setCanRenderTrees(boolean $canRenderTrees) : void +``` + +Set the flag indicating whether or not we should render trees of view models. If +set to true, the `Laminas\View\View` instance will not attempt to render children +separately, but instead pass the root view model directly to the `PhpRenderer`. +It is then up to the developer to render the children from within the view +script. This is typically done using the `RenderChildModel` helper: +`$this->renderChildModel('child_name')`. + +## Additional Methods + +Typically, you'll only ever access variables and [helpers](helpers/intro.md) +within your view scripts or when interacting with the `PhpRenderer`. However, +there are a few additional methods you may be interested in. + +Unless otherwise noted, class names are relative to the `Laminas\View` namespace. + +### render + +```php +render( + string|Model\ModelInterface $nameOrModel, + array|\Traversable $values = null +) : string +``` + +Render a template/view model. + +If `$nameOrModel` is a string, it is assumed to be a template name. That +template will be resolved using the current resolver, and then rendered. + +If `$values` is non-null, those values, and those values only, will be used +during rendering, and will replace whatever variable container previously was in +the renderer; however, the previous variable container will be reset when done. + +If `$values` is empty, the current variables container (see [setVars()](#setvars)) +will be injected when rendering. + +If `$nameOrModel` is a `ModelInterface` instance, the template name will be +retrieved from it and used. Additionally, if the model contains any variables, +these will be used when rendering; otherwise, the variables container already +present, if any, will be used. + +The method returns the script output. + +### resolver + +```php +resolver() : Resolver\ResolverInterface +``` + +Retrieves the current `Resolver` instance. + +### vars + +```php +vars(string $key = null) : mixed +``` + +Retrieve a single variable from the container if a key is provided; otherwise it +will return the variables container. + +### plugin + +```php +plugin(string $name, array $options = null) : Helper\HelperInterface +``` + +Retrieve a plugin/helper instance. Proxies to the plugin manager's `get()` +method; as such, any `$options` you pass will be passed to the plugin's +constructor if this is the first time the plugin has been retrieved. See the +section on [helpers](helpers/intro.md) for more information. + +### addTemplate + +```php +addTemplate(string $template) : void +``` + +Add a template to the stack. When used, the next call to `render()` will loop +through all templates added using this method, rendering them one by one; the +output of the last will be returned. diff --git a/docs/book/v3/quick-start.md b/docs/book/v3/quick-start.md new file mode 100644 index 000000000..483dd317a --- /dev/null +++ b/docs/book/v3/quick-start.md @@ -0,0 +1,781 @@ +# Quick Start + +laminas-view provides the "View" layer of Laminas's MVC system. It is a +multi-tiered system allowing a variety of mechanisms for extension, +substitution, and more. + +The components of the view layer are as follows: + +- **Variables Containers** hold variables and callbacks that you wish to + represent in the view. Often-times, a Variables Container will also provide + mechanisms for context-specific escaping of variables and more. +- **View Models** hold Variables Containers, specify the template to use (if + any), and optionally provide rendering options (more on that below). View + Models may be nested in order to represent complex structures. +- **Renderers** take View Models and provide a representation of them to return. + laminas-view ships with three renderers by default: a `PhpRenderer` which + utilizes PHP templates in order to generate markup, a `JsonRenderer`, and a + `FeedRenderer` for generating RSS and Atom feeds. +- **Resolvers** utilize Resolver Strategies to resolve a template name to a + resource a Renderer may consume. As an example, a Resolver may take the name + "blog/entry" and resolve it to a PHP view script. +- The **View** consists of strategies that map the current Request to a + Renderer, and strategies for injecting the result of rendering to the + Response. +- **Rendering Strategies** listen to the `Laminas\View\ViewEvent::EVENT_RENDERER` + event of the View and decide which Renderer should be selected based on the + Request or other criteria. +- **Response Strategies** are used to inject the Response object with the + results of rendering. That may also include taking actions such as setting + Content-Type headers. + +Additionally, laminas-mvc integrates with laminas-view via a number of event listeners +in the `Laminas\Mvc\View` namespace. + +This section of the manual is designed to show you typical usage patterns of the +view layer when using it with [laminas-mvc](https://docs.laminas.dev/laminas-mvc/). +The assumption is that you are using the [service manager](https://docs.laminas.dev/laminas-servicemanager/) +and the default MVC view strategies. + +## Configuration + +The default configuration will typically work out-of-the-box. However, you will +still need to select Resolver Strategies and configure them, as well as +potentially indicate alternate template names for things like the site layout, +404 (not found) pages, and error pages. The code snippets below can be added to +your configuration to accomplish this. We recommend adding it to a +site-specific module, such as the "Application" module from the framework's +[laminas-mvc-skeleton](https://github.com/laminas/laminas-mvc-skeleton), +or to one of your autoloaded configurations within the `config/autoload/` +directory. + +```php +return [ + 'view_manager' => [ + // The TemplateMapResolver allows you to directly map template names + // to specific templates. The following map would provide locations + // for a home page template ("application/index/index"), as well as for + // the layout ("layout/layout"), error pages ("error/index"), and + // 404 page ("error/404"), resolving them to view scripts. + 'template_map' => [ + 'application/index/index' => __DIR__ . '/../view/application/index/index.phtml', + 'site/layout' => __DIR__ . '/../view/layout/layout.phtml', + 'error/index' => __DIR__ . '/../view/error/index.phtml', + 'error/404' => __DIR__ . '/../view/error/404.phtml', + ], + + // The TemplatePathStack takes an array of directories. Directories + // are then searched in LIFO order (it's a stack) for the requested + // view script. This is a nice solution for rapid application + // development, but potentially introduces performance expense in + // production due to the number of static calls necessary. + // + // The following adds an entry pointing to the view directory + // of the current module. Make sure your keys differ between modules + // to ensure that they are not overwritten -- or simply omit the key! + 'template_path_stack' => [ + 'application' => __DIR__ . '/../view', + ], + + // This will be used as the default suffix for template scripts + // resolving, it defaults to 'phtml'. + 'default_template_suffix' => 'php', + + // Set the template name for the site's layout. + // + // By default, the MVC's default Rendering Strategy uses the + // template name "layout/layout" for the site's layout. + // Here, we tell it to use the "site/layout" template, + // which we mapped via the TemplateMapResolver above. + 'layout' => 'site/layout', + + // By default, the MVC registers an "exception strategy", which is + // triggered when a requested action raises an exception; it creates + // a custom view model that wraps the exception, and selects a + // template. We'll set it to "error/index". + // + // Additionally, we'll tell it that we want to display an exception + // stack trace; you'll likely want to disable this by default. + 'display_exceptions' => true, + 'exception_template' => 'error/index', + + // Another strategy the MVC registers by default is a "route not + // found" strategy. Basically, this gets triggered if (a) no route + // matches the current request, (b) the controller specified in the + // route match cannot be found in the service locator, (c) the controller + // specified in the route match does not implement the DispatchableInterface + // interface, or (d) if a response from a controller sets the + // response status to 404. + // + // The default template used in such situations is "error", just + // like the exception strategy. Here, we tell it to use the "error/404" + // template (which we mapped via the TemplateMapResolver, above). + // + // You can opt in to inject the reason for a 404 situation; see the + // various `Application\:\:ERROR_*`_ constants for a list of values. + // Additionally, a number of 404 situations derive from exceptions + // raised during routing or dispatching. You can opt-in to display + // these. + 'display_not_found_reason' => true, + 'not_found_template' => 'error/404', + ], +]; +``` + +## Controllers and View Models + +`Laminas\View\View` consumes `ViewModel`s, passing them to the selected renderer. +Where do you create these, though? + +The most explicit way is to create them in your controllers and return them. + +```php +namespace Foo\Controller; + +use Laminas\Mvc\Controller\AbstractActionController; +use Laminas\View\Model\ViewModel; + +class BazBatController extends AbstractActionController +{ + public function doSomethingCrazyAction() + { + $view = new ViewModel([ + 'message' => 'Hello world', + ]); + $view->setTemplate('foo/baz-bat/do-something-crazy'); + return $view; + } +} +``` + +This sets a "message" variable in the View Model, and sets the template name +"foo/baz-bat/do-something-crazy". The View Model is then returned. + +In most cases, you'll likely have a template name based on the module namespace, +controller, and action. Considering that, and if you're simply passing some +variables, could this be made simpler? Definitely. + +The MVC registers a couple of listeners for controllers to automate this. The +first will look to see if you returned an associative array from your +controller; if so, it will create a View Model and make this associative array +the Variables Container; this View Model then replaces the +[MvcEvent](https://docs.laminas.dev/laminas-mvc/mvc-event/)'s result. It will +also look to see if you returned nothing or `null`; if so, it will create a View +Model without any variables attached; this View Model also replaces the +`MvcEvent`'s result. + +The second listener checks to see if the `MvcEvent` result is a View Model, and, +if so, if it has a template associated with it. If not, it will inspect the +controller matched during routing to determine the module namespace and the +controller class name, and, if available, it's "action" parameter in order to +create a template name. This will be `module/controller/action`, all normalized +to lowercase, dash-separated words. + +As an example, the controller `Foo\Controller\BazBatController` with action +"doSomethingCrazyAction", would be mapped to the template +`foo/baz-bat/do-something-crazy`. As you can see, the words "Controller" and +"Action" are omitted. + +In practice, that means our previous example could be re-written as follows: + +```php +namespace Foo\Controller; + +use Laminas\Mvc\Controller\AbstractActionController; + +class BazBatController extends AbstractActionController +{ + public function doSomethingCrazyAction() + { + return [ + 'message' => 'Hello world', + ]; + } +} +``` + +The above method will likely work for the majority of use cases. When you need +to specify a different template, explicitly create and return a View Model and +specify the template manually, as in the first example. + +## Nesting View Models + +The other use case you may have for setting explicit View Models is if you wish +to **nest** them. In other words, you might want to render templates to be +included within the main View you return. + +As an example, you may want the View from an action to be one primary section +that includes both an "article" and a couple of sidebars; one of the sidebars +may include content from multiple Views as well: + +```php +namespace Content\Controller; + +use Laminas\Mvc\Controller\AbstractActionController; +use Laminas\View\Model\ViewModel; + +class ArticleController extends AbstractActionController +{ + public function viewAction() + { + // get the article from the persistence layer, etc... + + $view = new ViewModel(); + + // this is not needed since it matches "module/controller/action" + $view->setTemplate('content/article/view'); + + $articleView = new ViewModel(['article' => $article]); + $articleView->setTemplate('content/article'); + + $primarySidebarView = new ViewModel(); + $primarySidebarView->setTemplate('content/main-sidebar'); + + $secondarySidebarView = new ViewModel(); + $secondarySidebarView->setTemplate('content/secondary-sidebar'); + + $sidebarBlockView = new ViewModel(); + $sidebarBlockView->setTemplate('content/block'); + + $secondarySidebarView->addChild($sidebarBlockView, 'block'); + + $view->addChild($articleView, 'article') + ->addChild($primarySidebarView, 'sidebar_primary') + ->addChild($secondarySidebarView, 'sidebar_secondary'); + + return $view; + } +} +``` + +The above will create and return a View Model specifying the template +`content/article/view`. When the View is rendered, it will render three child +Views, the `$articleView`, `$primarySidebarView`, and `$secondarySidebarView`; +these will be captured to the `$view`'s `article`, `sidebar_primary`, and +`sidebar_secondary` variables, respectively, so that when it renders, you may +include that content. Additionally, the `$secondarySidebarView` will include an +additional View Model, `$sidebarBlockView`, which will be captured to its +`block` view variable. + +To better visualize this, let's look at what the final content might look like, +with comments detailing where each nested view model is injected. + +Here are the templates, rendered based on a 12-column grid. + +The `content/article/view` template: + +```php + +
    + article ?> + + sidebar_primary ?> + + sidebar_secondary ?> +
    +``` + +The `content/article` template: + +```php + +
    + escapeHtml('article') ?> +
    +``` + +The `content/main-sidebar` template: + +```php + + +``` + +The `content/secondary-sidebar` template: + +```php + + +``` + +The `content/block` template: + +```php + +
    + block content... +
    +``` + +And here is the aggregate, generated content: + +```html + +
    + +
    + Lorem ipsum .... +
    + + + + + + +
    +``` + +You can achieve very complex markup using nested Views, while simultaneously +keeping the details of rendering isolated from the Request/Response lifecycle of +the controller. + +## Dealing with Layouts + +Most sites enforce a cohesive look-and-feel which we typically call the site's +"layout". It includes the default stylesheets and JavaScript necessary, if any, +as well as the basic markup structure into which all site content will be +injected. + +Within laminas-mvc, layouts are handled via nesting of View Models ([see the +previous example](#nesting-view-models) for examples of View Model nesting). The +`Laminas\Mvc\View\Http\ViewManager` composes a View Model which acts as the "root" +for nested View Models. As such, it should contain the skeleton (or layout) +template for the site. All other content is then rendered and captured to view +variables of this root View Model. + +The `ViewManager` sets the layout template as `layout/layout` by default. To +change this, you can add some configuration to the `view_manager` area of your +[configuration](#configuration). + +A listener on the controllers, `Laminas\Mvc\View\Http\InjectViewModelListener`, +will take a View Model returned from a controller and inject it as a child of +the root (layout) View Model. By default, View Models will capture to the +"content" variable of the root View Model. This means you can do the following +in your layout view script: + +```php + + + <?= $this->headTitle() ?> + + + content; ?> + + +``` + +If you want to specify a different View variable for which to capture, +explicitly create a view model in your controller, and set its "capture to" +value: + +```php +namespace Foo\Controller; + +use Laminas\Mvc\Controller\AbstractActionController; +use Laminas\View\Model\ViewModel; + +class BazBatController extends AbstractActionController +{ + public function doSomethingCrazyAction() + { + $view = new ViewModel([ + 'message' => 'Hello world', + ]); + + // Capture to the layout view's "article" variable + $view->setCaptureTo('article'); + + return $view; + } +} +``` + +There will be times you don't want to render a layout. For example, you might be +answering an API call which expects JSON or an XML payload, or you might be +answering an XHR request that expects a partial HTML payload. To do this, +explicitly create and return a view model from your controller, and mark it as +"terminal", which will hint to the MVC listener that normally injects the +returned View Model into the layout View Model, to instead replace the layout +view model. + +```php +namespace Foo\Controller; + +use Laminas\Mvc\Controller\AbstractActionController; +use Laminas\View\Model\ViewModel; + +class BazBatController extends AbstractActionController +{ + public function doSomethingCrazyAction() + { + $view = new ViewModel([ + 'message' => 'Hello world', + ]); + + // Disable layouts; `MvcEvent` will use this View Model instead + $view->setTerminal(true); + + return $view; + } +} +``` + +[When discussing nesting View Models](#nesting-view-models), we detailed a +nested View Model which contained an article and sidebars. Sometimes, you may +want to provide additional View Models to the layout, instead of nesting in the +returned layout. This may be done by using the `layout()` controller plugin, +which returns the root View Model. You can then call the same `addChild()` +method on it as we did in that previous example. + +```php +namespace Content\Controller; + +use Laminas\Mvc\Controller\AbstractActionController; +use Laminas\View\Model\ViewModel; + +class ArticleController extends AbstractActionController +{ + public function viewAction() + { + // get the article from the persistence layer, etc... + + // Get the "layout" view model and inject a sidebar + $layout = $this->layout(); + $sidebarView = new ViewModel(); + $sidebarView->setTemplate('content/sidebar'); + $layout->addChild($sidebarView, 'sidebar'); + + // Create and return a view model for the retrieved article + $view = new ViewModel(['article' => $article]); + $view->setTemplate('content/article'); + return $view; + } +} +``` + +You could also use this technique to select a different layout, by calling the +`setTemplate()` method of the layout View Model: + +```php +//In a controller +namespace Content\Controller; + +use Laminas\Mvc\Controller\AbstractActionController; +use Laminas\View\Model\ViewModel; + +class ArticleController extends AbstractActionController +{ + public function viewAction() + { + // get the article from the persistence layer, etc... + + // Get the "layout" view model and set an alternate template + $layout = $this->layout(); + $layout->setTemplate('article/layout'); + + // Create and return a view model for the retrieved article + $view = new ViewModel(['article' => $article]); + $view->setTemplate('content/article'); + return $view; + } +} +``` + +Sometimes, you may want to access the layout from within your actual view +scripts when using the `PhpRenderer`. Reasons might include wanting to change +the layout template, or wanting to either access or inject layout view variables. +Similar to the `layout()` controller plugin, you can use the `layout()` View Helper. +If you provide a string argument to it, you will change the template; if you +provide no arguments, the root layout View Model is returned. + +```php +//In a view script + +// Change the layout: +$this->layout('alternate/layout'); // OR +$this->layout()->setTemplate('alternate/layout'); + +// Access a layout variable. +// Since access to the base view model is relatively easy, it becomes a +// reasonable place to store things such as API keys, which other view scripts +// may need. +$layout = $this->layout(); +$disqusApiKey = false; +if (isset($layout->disqusApiKey)) { + $disqusApiKey = $layout->disqusApiKey; +} + +// Set a layout variable +$this->layout()->footer = $this->render('article/footer'); +``` + +Commonly, you may want to alter the layout based on the current **module**. This +requires (a) detecting if the controller matched in routing belongs to this +module, and then (b) changing the template of the View Model. + +The place to do these actions is in a listener. It should listen either to the +`route` event at low (negative) priority, or on the `dispatch` event, at any +priority. Typically, you will register this during the bootstrap event. + +```php +namespace Content; + +use Laminas\Mvc\MvcEvent; + +class Module +{ + /** + * @param MvcEvent $e The MvcEvent instance + * @return void + */ + public function onBootstrap(MvcEvent $e) + { + // Register a dispatch event + $app = $e->getParam('application'); + $app->getEventManager()->attach('dispatch', [$this, 'setLayout']); + } + + /** + * @param MvcEvent $e The MvcEvent instance + * @return void + */ + public function setLayout(MvcEvent $e) + { + $matches = $e->getRouteMatch(); + $controller = $matches->getParam('controller'); + if (false === strpos($controller, __NAMESPACE__)) { + // not a controller from this module + return; + } + + // Set the layout template + $viewModel = $e->getViewModel(); + $viewModel->setTemplate('content/layout'); + } +} +``` + +## Creating and Registering Alternate Rendering and Response Strategies + +`Laminas\View\View` does very little. Its workflow is essentially to martial a +`ViewEvent`, and then trigger two events, `renderer` and `response`. You can +attach "strategies" to these events, using the methods `addRenderingStrategy()` +and `addResponseStrategy()`, respectively. A Rendering Strategy introspects the +Request object (or any other criteria) in order to select a Renderer (or fail to +select one). A Response Strategy determines how to populate the Response based +on the result of rendering. + +laminas-view ships with three Rendering and Response Strategies that you can use +within your application. + +- `Laminas\View\Strategy\PhpRendererStrategy`. This strategy is a "catch-all" in + that it will always return the `Laminas\View\Renderer\PhpRenderer` and populate + the Response body with the results of rendering. +- `Laminas\View\Strategy\JsonStrategy`. This strategy will return the + `Laminas\View\Renderer\JsonRenderer`, and populate the Response body with the + JSON value returned, as well as set a `Content-Type` header with a value of + `application/json`. +- `Laminas\View\Strategy\FeedStrategy`. This strategy will return the + `Laminas\View\Renderer\FeedRenderer`, setting the feed type to + either "rss" or "atom", based on what was matched. Its Response strategy will + populate the Response body with the generated feed, as well as set a + `Content-Type` header with the appropriate value based on feed type. + +By default, only the `PhpRendererStrategy` is registered, meaning you will need +to register the other Strategies yourself if you want to use them. Additionally, +it means that you will likely want to register these at higher priority to +ensure they match before the `PhpRendererStrategy`. As an example, let's +register the `JsonStrategy`: + +```php +namespace Application; + +use Laminas\Mvc\MvcEvent; + +class Module +{ + /** + * @param MvcEvent $e The MvcEvent instance + * @return void + */ + public function onBootstrap(MvcEvent $e) + { + // Register a "render" event, at high priority (so it executes prior + // to the view attempting to render) + $app = $e->getApplication(); + $app->getEventManager()->attach('render', [$this, 'registerJsonStrategy'], 100); + } + + /** + * @param MvcEvent $e The MvcEvent instance + * @return void + */ + public function registerJsonStrategy(MvcEvent $e) + { + $app = $e->getTarget(); + $locator = $app->getServiceManager(); + $view = $locator->get('Laminas\View\View'); + $jsonStrategy = $locator->get('ViewJsonStrategy'); + + // Attach strategy, which is a listener aggregate, at high priority + $jsonStrategy->attach($view->getEventManager(), 100); + } +} +``` + +The above will register the `JsonStrategy` with the "render" event, such that it +executes prior to the `PhpRendererStrategy`, and thus ensure that a JSON payload +is created when the controller returns a `JsonModel`. + +You could also use the module configuration to add the strategies: + +```php +namespace Application; + +use Laminas\ModuleManager\Feature\ConfigProviderInterface; + +class Module implements ConfigProviderInterface +{ + /** + * Returns configuration to merge with application configuration + * + * @return array + */ + public function getConfig() + { + return [ + /* ... */ + 'view_manager' => [ + /* ... */ + 'strategies' => [ + 'ViewJsonStrategy', + ], + ], + ]; + } +} +``` + +What if you want this to happen only in specific modules, or specific +controllers? One way is similar to the last example in the +[previous section on layouts](#dealing-with-layouts), where we detailed changing +the layout for a specific module: + +```php +namespace Application; + +use Laminas\Mvc\MvcEvent; + +class Module +{ + /** + * @param MvcEvent $e The MvcEvent instance + * @return void + */ + public function onBootstrap(MvcEvent $e) + { + // Register a render event + $app = $e->getParam('application'); + $app->getEventManager()->attach('render', [$this, 'registerJsonStrategy'], 100); + } + + /** + * @param MvcEvent $e The MvcEvent instance + * @return void + */ + public function registerJsonStrategy(MvcEvent $e) + { + $matches = $e->getRouteMatch(); + $controller = $matches->getParam('controller'); + if (false === strpos($controller, __NAMESPACE__)) { + // not a controller from this module + return; + } + + // Potentially, you could be even more selective at this point, and test + // for specific controller classes, and even specific actions or request + // methods. + + // Set the JSON strategy when controllers from this module are selected + $app = $e->getTarget(); + $locator = $app->getServiceManager(); + $view = $locator->get('Laminas\View\View'); + $jsonStrategy = $locator->get('ViewJsonStrategy'); + + // Attach strategy, which is a listener aggregate, at high priority + $jsonStrategy->attach($view->getEventManager(), 100); + } +} +``` + +While the above examples detail using the `JsonStrategy`, the same could be done +for the `FeedStrategy`. + +If you successfully registered the Strategy you need to use the appropriate `ViewModel`: + +```php +namespace Application; + +use Laminas\Mvc\Controller\AbstractActionController; +use Laminas\View\Model\ViewModel; +use Laminas\View\Model\JsonModel; +use Laminas\View\Model\FeedModel; + +class MyController extends AbstractActionController +{ + /** + * Lists the items as HTML + */ + public function listAction() + { + $items = /* ... get items ... */; + $viewModel = new ViewModel(); + $viewModel->setVariable('items', $items); + return $viewModel; + } + + /** + * Lists the items as JSON + */ + public function listJsonAction() + { + $items = /* ... get items ... */; + $viewModel = new JsonModel(); + $viewModel->setVariable('items', $items); + return $viewModel; + } + + /** + * Lists the items as a Feed + */ + public function listFeedAction() + { + $items = /* ... get items ... */; + $viewModel = new FeedModel(); + $viewModel->setVariable('items', $items); + return $viewModel; + } +} +``` + +Or you could switch the `ViewModel` dynamically based on the "Accept" HTTP Header with the +[Laminas-Mvc-Plugin AcceptableViewModelSelector](https://docs.laminas.dev/laminas-mvc/plugins/#acceptableviewmodelselector-plugin). diff --git a/docs/book/v3/view-event.md b/docs/book/v3/view-event.md new file mode 100644 index 000000000..ae3bb811c --- /dev/null +++ b/docs/book/v3/view-event.md @@ -0,0 +1,131 @@ +# The ViewEvent + +laminas-view incorporates and utilizes a custom [laminas-eventmanager +Event](https://laminas.github.com/laminas-eventmanager) implementation, +`Laminas\View\ViewEvent`. This event is created during `Laminas\View\View::getEvent()` +and is passed directly to all the events the `View` class triggers. + +The `ViewEvent` adds accessors and mutators for the following: + +- `Model` object, typically representing the layout view model. +- `Renderer` object. +- `Request` object. +- `Response` object. +- `Result` (typically a string representing the rendered content). + +The methods it defines are: + +- `setModel(Model $model)` +- `getModel()` +- `setRequest($request)` +- `getRequest()` +- `setResponse($response)` +- `getResponse()` +- `setRenderer($renderer)` +- `getRenderer()` +- `setResult($result)` +- `getResult()` + +## Order of events + +The following events are triggered, in the following order: + +Name | Constant | Description +--------------- | -------------------------------- | ----------- +`renderer` | `ViewEvent::EVENT_RENDERER` | Render the view, with the help of renderers. +`renderer.post` | `ViewEvent::EVENT_RENDERER_POST` | Triggers after the view is rendered. +`response` | `ViewEvent::EVENT_RESPONSE` | Populate the response from the view. + +Each is described in the following sections. + +## ViewEvent::EVENT\_RENDERER + +### Listeners + +The following classes are listening to this event (they are sorted from higher priority to lower +priority): + +#### For PhpStrategy + +This listener is added when the strategy used for rendering is `PhpStrategy`: + +Class | Priority | Method called | Description +-------------------------------- | -------- | ---------------- | ----------- +`Laminas\View\Strategy\PhpStrategy` | 1 | `selectRenderer` | Return a `PhpRenderer` + +#### For JsonStrategy + +This listener is added when the strategy used for rendering is `JsonStrategy`: + +Class | Priority | Method called | Description +--------------------------------- | -------- | ---------------- | ----------- +`Laminas\View\Strategy\JsonStrategy` | 1 | `selectRenderer` | Return a `JsonRenderer` + +#### For FeedStrategy + +This listener is added when the strategy used for rendering is `FeedStrategy`: + +Class | Priority | Method called | Description +--------------------------------- | -------- | ---------------- | ----------- +`Laminas\View\Strategy\FeedStrategy` | 1 | `selectRenderer` | Return a `FeedRenderer` + +### Triggerers + +This event is triggered by the following classes: + +Class | In method | Description +---------------- | --------- | ----------- +`Laminas\View\View` | `render` | It has a short circuit callback that stops propagation once one result return an instance of a Renderer. + +## ViewEvent::EVENT\_RENDERER\_POST + +### Listeners + +There are currently no built-in listeners for this event. + +### Triggerers + +This event is triggered by the following classes: + +Class | In method | Description +---------------- | --------- | ----------- +`Laminas\View\View` | `render` | This event is triggered after `ViewEvent::EVENT_RENDERER` and before `ViewEvent::EVENT_RESPONSE`. + +## ViewEvent::EVENT\_RESPONSE + +### Listeners + +The following classes are listening to this event (they are sorted from higher priority to lower +priority): + +#### For PhpStrategy + +This listener is added when the strategy used for rendering is `PhpStrategy`: + +Class | Priority | Method called | Description +-------------------------------- | -------- | ---------------- | ----------- +`Laminas\View\Strategy\PhpStrategy` | 1 | `injectResponse` | Populate the `Response` object from the rendered view. + +#### For JsonStrategy + +This listener is added when the strategy used for rendering is `JsonStrategy`: + +Class | Priority | Method called | Description +--------------------------------- | -------- | ---------------- | ----------- +`Laminas\View\Strategy\JsonStrategy` | 1 | `injectResponse` | Populate the `Response` object with the serialized JSON content. + +#### For FeedStrategy + +This listener is added when the strategy used for rendering is `FeedStrategy`: + +Class | Priority | Method called | Description +--------------------------------- | -------- | ---------------- | ----------- +`Laminas\View\Strategy\FeedStrategy` | 1 | `injectResponse` | Populate the `Response` object with the rendered feed. + +### Triggerers + +This event is triggered by the following classes: + +Class | In method | Description +---------------- | --------- | ----------- +`Laminas\View\View` | `render` | This event is triggered after `ViewEvent::EVENT_RENDERER` and `ViewEvent::EVENT_RENDERER_POST`. diff --git a/docs/book/v3/view-scripts.md b/docs/book/v3/view-scripts.md new file mode 100644 index 000000000..feacbaeef --- /dev/null +++ b/docs/book/v3/view-scripts.md @@ -0,0 +1,99 @@ +# View Scripts + +Once you call `render()`, `Laminas\View\Renderer\PhpRenderer` then `include()`s the +requested view script and executes it "inside" the scope of the `PhpRenderer` +instance. Therefore, in your view scripts, references to `$this` actually point +to the `PhpRenderer` instance itself. + +## Variables + +Variables assigned to the view, either via a [View Model](quick-start.md#controllers-and-view-models), +[Variables container](quick-start.md), or by passing an array of variables to +`render()`, may be retrieved in three ways: + +- Explicitly, by retrieving them from the `Variables` container composed in the + `PhpRenderer`: `$this->vars()->varname`. +- As instance properties of the `PhpRenderer` instance: `$this->varname`. (In + this situation, instance property access is proxying to the composed + `Variables` instance.) +- As local PHP variables: `$varname`. The `PhpRenderer` extracts the members of + the `Variables` container locally. + +We generally recommend using the second notation, as it's less verbose than the +first, but differentiates between variables in the view script scope and those +assigned to the renderer from elsewhere. + +By way of reminder, here is the example view script from the `PhpRenderer` +introduction. + +```php +books): ?> + + + + + + + + + books as $key => $val): ?> + + + + + + +
    AuthorTitle
    escapeHtml($val['author']) ?>escapeHtml($val['title']) ?>
    + + + +

    There are no books to display.

    + + +``` + +> TIP: **IDE Auto-Completion in View Scripts** +> The `Laminas\View\Renderer\PhpRenderer` class can be used to provide auto-completion for modern IDEs. +> It defines the aliases of the view helpers in a DocBlock as `@method` tags. +> +> ### Usage +> +> In order to allow auto-completion in view scripts, `$this` variable should be type-hinted via a DocBlock at the top of a view script. +> It is recommended that always the `Laminas\View\Renderer\PhpRenderer` is added as the first type, so that the IDE can auto-suggest the default view helpers from `laminas-view`: +> +> ```php +> /** +> * @var Laminas\View\Renderer\PhpRenderer $this +> */ +> ``` +> +> The different Laminas components that contain view helpers provide `HelperTrait` traits with more aliases of the view helpers. +> These traits can be chained with a pipe symbol (a.k.a. vertical bar) `|` as many as needed, depending on which view helpers from the different Laminas component are used and where the auto-completion is to be made. + +## Escaping Output + +One of the most important tasks to perform in a view script is to make sure that +output is escaped properly; among other things, this helps to avoid cross-site +scripting attacks. Unless you are using a function, method, or helper that does +escaping on its own, you should always escape variables when you output them and +pay careful attention to applying the correct escaping strategy to each HTML +context you use. + +The `PhpRenderer` includes a selection of helpers you can use for this purpose: +`EscapeHtml`, `EscapeHtmlAttr`, `EscapeJs`, `EscapeCss`, and `EscapeUrl`. +Matching the correct helper (or combination of helpers) to the context into +which you are injecting untrusted variables will ensure that you are protected +against Cross-Site Scripting (XSS) vulnerabilities. + +```php +// bad view-script practice: +echo $this->variable; + +// good view-script practice: +echo $this->escapeHtml($this->variable); + +// and remember context is always relevant! + +``` diff --git a/mkdocs.yml b/mkdocs.yml index 0cc03866c..c8d4e4643 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -39,46 +39,84 @@ nav: - "Setting module-specific Layouts": v2/cookbook/setting-module-specific-layouts.md - Migration: - "Preparing for Version 3": v2/migration/preparing-for-v3.md + - v3: + - "Quick Start": v3/quick-start.md + - "Rendering Views": + - "The PhpRenderer": v3/php-renderer.md + - "View Scripts": v3/view-scripts.md + - "The ViewEvent": v3/view-event.md + - Helpers: + - Introduction: v3/helpers/intro.md + - Asset: v3/helpers/asset.md + - BasePath: v3/helpers/base-path.md + - Cycle: v3/helpers/cycle.md + - Doctype: v3/helpers/doctype.md + - Escape: v3/helpers/escape.md + - Gravatar: v3/helpers/gravatar-image.md + - HeadLink: v3/helpers/head-link.md + - HeadMeta: v3/helpers/head-meta.md + - HeadScript: v3/helpers/head-script.md + - HeadStyle: v3/helpers/head-style.md + - HeadTitle: v3/helpers/head-title.md + - HtmlAttributes: v3/helpers/html-attributes.md + - HtmlList: v3/helpers/html-list.md + - HtmlObject: v3/helpers/html-object.md + - HtmlTag: v3/helpers/html-tag.md + - Identity: v3/helpers/identity.md + - InlineScript: v3/helpers/inline-script.md + - Json: v3/helpers/json.md + - Layout: v3/helpers/layout.md + - Partial: v3/helpers/partial.md + - Placeholder: v3/helpers/placeholder.md + - Url: v3/helpers/url.md + - "Advanced usage of helpers": v3/helpers/advanced-usage.md + - 'Application Integration': + - 'Stand-Alone': v3/application-integration/stand-alone.md + - Cookbook: + - "Setting module-specific Layouts": v3/cookbook/setting-module-specific-layouts.md site_name: laminas-view site_description: 'Flexible view layer supporting and providing multiple view layers, helpers, and more.' repo_url: 'https://github.com/laminas/laminas-view' extra: project: Components - current_version: v2 + current_version: v3 versions: - v2 + - v3 plugins: - redirects: redirect_maps: - quick-start.md: v2/quick-start.md - php-renderer.md: v2/php-renderer.md - view-scripts.md: v2/view-scripts.md - view-event.md: v2/view-event.md - helpers/intro.md: v2/helpers/intro.md - helpers/asset.md: v2/helpers/asset.md - helpers/base-path.md: v2/helpers/base-path.md - helpers/cycle.md: v2/helpers/cycle.md - helpers/doctype.md: v2/helpers/doctype.md - helpers/escape.md: v2/helpers/escape.md + # Old helpers no longer present in v3 helpers/flash-messenger.md: v2/helpers/flash-messenger.md helpers/gravatar.md: v2/helpers/gravatar.md - helpers/head-link.md: v2/helpers/head-link.md - helpers/head-meta.md: v2/helpers/head-meta.md - helpers/head-script.md: v2/helpers/head-script.md - helpers/head-style.md: v2/helpers/head-style.md - helpers/head-title.md: v2/helpers/head-title.md - helpers/html-attributes.md: v2/helpers/html-attributes.md - helpers/html-list.md: v2/helpers/html-list.md - helpers/html-object.md: v2/helpers/html-object.md - helpers/html-tag.md: v2/helpers/html-tag.md - helpers/identity.md: v2/helpers/identity.md - helpers/inline-script.md: v2/helpers/inline-script.md - helpers/json.md: v2/helpers/json.md - helpers/layout.md: v2/helpers/layout.md - helpers/partial.md: v2/helpers/partial.md - helpers/placeholder.md: v2/helpers/placeholder.md - helpers/url.md: v2/helpers/url.md - helpers/advanced-usage.md: v2/helpers/advanced-usage.md - application-integration/stand-alone.md: v2/application-integration/stand-alone.md - cookbook/setting-module-specific-layouts.md: v2/cookbook/setting-module-specific-layouts.md + # Existing content with an equivalent target in the v3 docs tree + quick-start.md: v3/quick-start.md + php-renderer.md: v3/php-renderer.md + view-scripts.md: v3/view-scripts.md + view-event.md: v3/view-event.md + helpers/intro.md: v3/helpers/intro.md + helpers/asset.md: v3/helpers/asset.md + helpers/base-path.md: v3/helpers/base-path.md + helpers/cycle.md: v3/helpers/cycle.md + helpers/doctype.md: v3/helpers/doctype.md + helpers/escape.md: v3/helpers/escape.md + helpers/head-link.md: v3/helpers/head-link.md + helpers/head-meta.md: v3/helpers/head-meta.md + helpers/head-script.md: v3/helpers/head-script.md + helpers/head-style.md: v3/helpers/head-style.md + helpers/head-title.md: v3/helpers/head-title.md + helpers/html-attributes.md: v3/helpers/html-attributes.md + helpers/html-list.md: v3/helpers/html-list.md + helpers/html-object.md: v3/helpers/html-object.md + helpers/html-tag.md: v3/helpers/html-tag.md + helpers/identity.md: v3/helpers/identity.md + helpers/inline-script.md: v3/helpers/inline-script.md + helpers/json.md: v3/helpers/json.md + helpers/layout.md: v3/helpers/layout.md + helpers/partial.md: v3/helpers/partial.md + helpers/placeholder.md: v3/helpers/placeholder.md + helpers/url.md: v3/helpers/url.md + helpers/advanced-usage.md: v3/helpers/advanced-usage.md + application-integration/stand-alone.md: v3/application-integration/stand-alone.md + cookbook/setting-module-specific-layouts.md: v3/cookbook/setting-module-specific-layouts.md From 775145ff5d1eda2832729f4aa26596ffcf4b28d1 Mon Sep 17 00:00:00 2001 From: George Steel Date: Wed, 18 Oct 2023 10:12:24 +0100 Subject: [PATCH 39/58] Reset the v2 docs tree to the same state as current v2.31.0 Signed-off-by: George Steel --- docs/book/v2/helpers/flash-messenger.md | 146 ++++++++++++++++++++++++ docs/book/v2/helpers/html-object.md | 4 +- docs/book/v2/helpers/intro.md | 7 +- docs/book/v2/helpers/json.md | 26 +++++ 4 files changed, 176 insertions(+), 7 deletions(-) create mode 100644 docs/book/v2/helpers/flash-messenger.md diff --git a/docs/book/v2/helpers/flash-messenger.md b/docs/book/v2/helpers/flash-messenger.md new file mode 100644 index 000000000..95a21fb99 --- /dev/null +++ b/docs/book/v2/helpers/flash-messenger.md @@ -0,0 +1,146 @@ +# FlashMessenger + +The `FlashMessenger` helper is used to render the messages of the +[FlashMessenger MVC plugin](https://docs.laminas.dev/laminas-mvc-plugin-flashmessenger/). + +## Basic Usage + +When only using the default `namespace` for the `FlashMessenger`, you can do the +following: + +```php +// Usable in any of your .phtml files +echo $this->flashMessenger()->render(); +``` + +The first argument of the `render()` function is the `namespace`. If no +`namespace` is defined, the default +`Laminas\Mvc\Controller\Plugin\FlashMessenger::NAMESPACE_DEFAULT` will be used, +which translates to `default`. + +```php +// Usable in any of your .phtml files +echo $this->flashMessenger()->render('error'); + +// Alternatively use one of the pre-defined namespaces +// (aka: use Laminas\Mvc\Controller\Plugin\FlashMessenger;) +echo $this->flashMessenger()->render(FlashMessenger::NAMESPACE_SUCCESS); +``` + +## CSS Layout + +The `FlashMessenger` default rendering adds a CSS class to the generated HTML, +that matches the defined `namespace` that should be rendered. While it may work +well for the default cases, every so often you may want to add specific CSS +classes to the HTML output. This can be done while making use of the second +parameter of the `render()` function. + +```php +// Usable in any of your .phtml files +echo $this->flashMessenger()->render('error', ['alert', 'alert-danger']); +``` + +The output of this example, using the default HTML rendering settings, would +look like this: + +```html +
      +
    • Some FlashMessenger Content
    • +
    • You, the developer, are AWESOME!
    • +
    +``` + +## HTML Layout + +Aside from modifying the rendered CSS classes of the `FlashMessenger`, you are +furthermore able to modify the generated HTML as a whole to create even more +distinct visuals for your flash messages. The default output format is defined +within the source code of the `FlashMessenger` view helper itself. + +```php +// Laminas/View/Helper/FlashMessenger.php#L41-L43 +protected $messageCloseString = '
  • '; +protected $messageOpenFormat = '
  • '; +protected $messageSeparatorString = '
  • '; +``` + +These defaults exactly match what we're trying to do. The placeholder `%s` will +be filled with the CSS classes output. + +To change this, all we need to do is call the respective setter methods of these +variables and give them new strings; for example: + +```php +// In any of your .phtml files: +echo $this->flashMessenger() + ->setMessageOpenFormat('

    ') + ->setMessageSeparatorString('

    ') + ->setMessageCloseString('

    ') + ->render('success'); +``` + +The above code sample then would then generate the following output: + +```html +
    +

    Some FlashMessenger Content

    +

    You, who's reading the docs, are AWESOME!

    +
    +``` + +## Sample Modification for Twitter Bootstrap 3 + +Taking all the above knowledge into account, we can create a nice, highly usable +and user-friendly rendering strategy using the +[Bootstrap front-end framework](http://getbootstrap.com/) version 3 layouts: + +```php +// In any of your .phtml files: +$flash = $this->flashMessenger(); +$flash->setMessageOpenFormat(' + +
    • ') + ->setMessageSeparatorString('
    • ') + ->setMessageCloseString('
    '); + +echo $flash->render('error', ['alert', 'alert-dismissible', 'alert-danger']); +echo $flash->render('info', ['alert', 'alert-dismissible', 'alert-info']); +echo $flash->render('default', ['alert', 'alert-dismissible', 'alert-warning']); +echo $flash->render('success', ['alert', 'alert-dismissible', 'alert-success']); +``` + +The output of the above example would create dismissable `FlashMessages` with +the following HTML markup. The example only covers one type of `FlashMessenger` +output; if you would have several `FlashMessages` available in each of the +rendered `namespaces`, then you would receive the same output multiple times +only having different CSS classes applied. + +```html +
    + +
      +
    • Some FlashMessenger Content
    • +
    • You, who's reading the docs, are AWESOME!
    • +
    +
    +``` + +## Alternative Configuration of the ViewHelper Layout + +`Laminas\View\Helper\Service\FlashMessengerFactory` checks the application +configuration, making it possible to set up the `FlashMessenger` strings through +your `module.config.php`, too. The next example will set up the output to be +identical with the above Twitter Bootstrap 3 Example + +```php +'view_helper_config' => [ + 'flashmessenger' => [ + 'message_open_format' => '
    • ', + 'message_close_string' => '
    ', + 'message_separator_string' => '
  • ', + ], +], +``` diff --git a/docs/book/v2/helpers/html-object.md b/docs/book/v2/helpers/html-object.md index ba1ecfa18..276a4a076 100644 --- a/docs/book/v2/helpers/html-object.md +++ b/docs/book/v2/helpers/html-object.md @@ -2,10 +2,12 @@ The [HTML `` element](https://developer.mozilla.org/en-US/docs/Web/HTML/Element/object) is used for embedding external media in web pages. The object view helpers take care of embedding media with minimum effort. -There are two initial Object helpers: +There are four initial Object helpers: - `htmlObject()` Generates markup for embedding a custom Object. - `htmlPage()` Generates markup for embedding other (X)HTML pages. +- `htmlFlash()` Generates markup for embedding Flash files. _**Deprecated**_ +- `htmlQuicktime()` Generates markup for embedding QuickTime files. _**Deprecated**_ All of these helpers share a similar interface. For this reason, this documentation will only contain examples of two of these helpers. diff --git a/docs/book/v2/helpers/intro.md b/docs/book/v2/helpers/intro.md index 1aa4a08f1..772b80990 100644 --- a/docs/book/v2/helpers/intro.md +++ b/docs/book/v2/helpers/intro.md @@ -60,6 +60,7 @@ for, and rendering, the various HTML `` tags, such as `HeadTitle`, - [BasePath](base-path.md) - [Cycle](cycle.md) - [Doctype](doctype.md) +- [FlashMessenger](flash-messenger.md) - [Gravatar](gravatar.md) *(Deprecated)* - [GravatarImage](gravatar-image.md) - [HeadLink](head-link.md) @@ -109,12 +110,6 @@ for, and rendering, the various HTML `` tags, such as `HeadTitle`, > [Paginator Usage](https://docs.laminas.dev/laminas-paginator/usage/#rendering-pages-with-view-scripts) > documentation. -> ### FlashMessenger helper -> -> View helper related to **Flash Messenger** is documented in the -> [FLash Messenger View Helper](https://docs.laminas.dev/laminas-mvc-plugin-flashmessenger/view-helper/) -> documentation. - > ### Custom Helpers > > For documentation on writing **custom view helpers** see the diff --git a/docs/book/v2/helpers/json.md b/docs/book/v2/helpers/json.md index 655a9f788..4a4056a02 100644 --- a/docs/book/v2/helpers/json.md +++ b/docs/book/v2/helpers/json.md @@ -19,3 +19,29 @@ determine how to handle the content. ```php json($this->data) ?> ``` + +> WARNING: **Deprecated** +> +> ### Enabling encoding using Laminas\Json\Expr +> +> **This feature of the Json view helper has been deprecated in version 2.16 and will be removed in version 3.0.** +> +> The JSON helper accepts an array of options that will be passed to `Laminas\Json\Json::encode()` and +> used internally to encode data. +> `Laminas\Json\Json::encode` allows the encoding of native JSON expressions using `Laminas\Json\Expr` +> objects. This option is disabled by default. To enable this option, pass a boolean `true` to the +> `enableJsonExprFinder` key of the options array: +> +> ```php +> json($this->data, ['enableJsonExprFinder' => true]) ?> +> `` +> +> The JSON helper accepts an array of options that will be passed to `Laminas\Json\Json::encode()` and +> used internally to encode data. +> `Laminas\Json\Json::encode` allows the encoding of native JSON expressions using `Laminas\Json\Expr` +> objects. This option is disabled by default. To enable this option, pass a boolean `true` to the +> `enableJsonExprFinder` key of the options array: +> +> ```php +> json($this->data, ['enableJsonExprFinder' => true]) ?> +> ``` From 9fee34729af1fcfbd31c819f24b9bc4cfd63c899 Mon Sep 17 00:00:00 2001 From: George Steel Date: Fri, 3 Nov 2023 13:53:57 +0000 Subject: [PATCH 40/58] Refresh lock post merge-up Signed-off-by: George Steel --- composer.lock | 337 ++++++++++++++------------------------------------ 1 file changed, 94 insertions(+), 243 deletions(-) diff --git a/composer.lock b/composer.lock index a1cafe8c0..9d6e326cf 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "a61a572e9d32a9124086e1adf8b50d56", + "content-hash": "b0c418f8e21dfd1b22c09c160f09f84d", "packages": [ { "name": "laminas/laminas-escaper", @@ -393,89 +393,6 @@ "source": "https://github.com/php-fig/container/tree/1.1.2" }, "time": "2021-11-05T16:50:12+00:00" - }, - { - "name": "symfony/polyfill-mbstring", - "version": "v1.28.0", - "source": { - "type": "git", - "url": "https://github.com/symfony/polyfill-mbstring.git", - "reference": "42292d99c55abe617799667f454222c54c60e229" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/42292d99c55abe617799667f454222c54c60e229", - "reference": "42292d99c55abe617799667f454222c54c60e229", - "shasum": "" - }, - "require": { - "php": ">=7.1" - }, - "provide": { - "ext-mbstring": "*" - }, - "suggest": { - "ext-mbstring": "For best performance" - }, - "type": "library", - "extra": { - "branch-alias": { - "dev-main": "1.28-dev" - }, - "thanks": { - "name": "symfony/polyfill", - "url": "https://github.com/symfony/polyfill" - } - }, - "autoload": { - "files": [ - "bootstrap.php" - ], - "psr-4": { - "Symfony\\Polyfill\\Mbstring\\": "" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Nicolas Grekas", - "email": "p@tchwork.com" - }, - { - "name": "Symfony Community", - "homepage": "https://symfony.com/contributors" - } - ], - "description": "Symfony polyfill for the Mbstring extension", - "homepage": "https://symfony.com", - "keywords": [ - "compatibility", - "mbstring", - "polyfill", - "portable", - "shim" - ], - "support": { - "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.28.0" - }, - "funding": [ - { - "url": "https://symfony.com/sponsor", - "type": "custom" - }, - { - "url": "https://github.com/fabpot", - "type": "github" - }, - { - "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", - "type": "tidelift" - } - ], - "time": "2023-07-28T09:04:16+00:00" } ], "packages-dev": [ @@ -1541,23 +1458,23 @@ }, { "name": "laminas/laminas-filter", - "version": "2.32.0", + "version": "2.33.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-filter.git", - "reference": "2b7e6b2b26a92412c38336ee3089251164edf141" + "reference": "6ad64828d25ec4bdf226ec5096aabb04aa710324" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-filter/zipball/2b7e6b2b26a92412c38336ee3089251164edf141", - "reference": "2b7e6b2b26a92412c38336ee3089251164edf141", + "url": "https://api.github.com/repos/laminas/laminas-filter/zipball/6ad64828d25ec4bdf226ec5096aabb04aa710324", + "reference": "6ad64828d25ec4bdf226ec5096aabb04aa710324", "shasum": "" }, "require": { "ext-mbstring": "*", "laminas/laminas-servicemanager": "^3.21.0", "laminas/laminas-stdlib": "^3.13.0", - "php": "~8.1.0 || ~8.2.0" + "php": "~8.1.0 || ~8.2.0 || ~8.3.0" }, "conflict": { "laminas/laminas-validator": "<2.10.1", @@ -1566,12 +1483,13 @@ "require-dev": { "laminas/laminas-coding-standard": "~2.5.0", "laminas/laminas-crypt": "^3.10", - "laminas/laminas-uri": "^2.10", + "laminas/laminas-i18n": "^2.23.1", + "laminas/laminas-uri": "^2.11", "pear/archive_tar": "^1.4.14", - "phpunit/phpunit": "^10.1.3", + "phpunit/phpunit": "^10.4.2", "psalm/plugin-phpunit": "^0.18.4", "psr/http-factory": "^1.0.2", - "vimeo/psalm": "^5.11" + "vimeo/psalm": "^5.15.0" }, "suggest": { "laminas/laminas-crypt": "Laminas\\Crypt component, for encryption filters", @@ -1615,7 +1533,7 @@ "type": "community_bridge" } ], - "time": "2023-05-16T23:25:05+00:00" + "time": "2023-11-03T13:29:10+00:00" }, { "name": "laminas/laminas-http", @@ -2054,75 +1972,6 @@ ], "time": "2022-12-02T15:45:50+00:00" }, - { - "name": "laminas/laminas-mvc-plugin-flashmessenger", - "version": "1.9.0", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-mvc-plugin-flashmessenger.git", - "reference": "dc73bb6b56a0d74f9fdc0d24ec55a5f8c87c4cfa" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-mvc-plugin-flashmessenger/zipball/dc73bb6b56a0d74f9fdc0d24ec55a5f8c87c4cfa", - "reference": "dc73bb6b56a0d74f9fdc0d24ec55a5f8c87c4cfa", - "shasum": "" - }, - "require": { - "laminas/laminas-mvc": "^3.3", - "laminas/laminas-session": "^2.12.0", - "laminas/laminas-stdlib": "^3.6.4", - "laminas/laminas-view": "^2.13.1", - "php": "~8.0.0 || ~8.1.0 || ~8.2.0" - }, - "conflict": { - "laminas/laminas-mvc": "<3.0.0", - "zendframework/zend-mvc-plugin-flashmessenger": "*" - }, - "require-dev": { - "laminas/laminas-coding-standard": "~2.4.0", - "laminas/laminas-i18n": "^2.19.0", - "phpunit/phpunit": "^9.5.25", - "psalm/plugin-phpunit": "^0.17.0", - "vimeo/psalm": "^4.29.0" - }, - "type": "library", - "extra": { - "laminas": { - "component": "Laminas\\Mvc\\Plugin\\FlashMessenger" - } - }, - "autoload": { - "psr-4": { - "Laminas\\Mvc\\Plugin\\FlashMessenger\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Plugin for creating and exposing flash messages via laminas-mvc controllers", - "homepage": "https://laminas.dev", - "keywords": [ - "laminas", - "mvc" - ], - "support": { - "chat": "https://laminas.dev/chat", - "docs": "https://docs.laminas.dev/laminas-mvc-plugin-flashmessenger/", - "forum": "https://discourse.laminas.dev", - "issues": "https://github.com/laminas/laminas-mvc-plugin-flashmessenger/issues", - "rss": "https://github.com/laminas/laminas-mvc-plugin-flashmessenger/releases.atom", - "source": "https://github.com/laminas/laminas-mvc-plugin-flashmessenger" - }, - "funding": [ - { - "url": "https://funding.communitybridge.org/projects/laminas-project", - "type": "community_bridge" - } - ], - "time": "2022-10-22T12:47:30+00:00" - }, { "name": "laminas/laminas-navigation", "version": "2.18.1", @@ -2418,87 +2267,6 @@ ], "time": "2023-11-02T17:21:39+00:00" }, - { - "name": "laminas/laminas-session", - "version": "2.16.0", - "source": { - "type": "git", - "url": "https://github.com/laminas/laminas-session.git", - "reference": "9c845a0361625d5775cad6f043716196201ad41f" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-session/zipball/9c845a0361625d5775cad6f043716196201ad41f", - "reference": "9c845a0361625d5775cad6f043716196201ad41f", - "shasum": "" - }, - "require": { - "laminas/laminas-eventmanager": "^3.5", - "laminas/laminas-servicemanager": "^3.15.1", - "laminas/laminas-stdlib": "^3.10.1", - "php": "~8.0.0 || ~8.1.0 || ~8.2.0" - }, - "conflict": { - "zendframework/zend-session": "*" - }, - "require-dev": { - "laminas/laminas-cache": "^3.8", - "laminas/laminas-cache-storage-adapter-memory": "^2.2", - "laminas/laminas-coding-standard": "~2.4.0", - "laminas/laminas-db": "^2.15", - "laminas/laminas-http": "^2.17.1", - "laminas/laminas-validator": "^2.28", - "mongodb/mongodb": "~1.13.0", - "phpunit/phpunit": "^9.5.26", - "psalm/plugin-phpunit": "^0.18.0", - "vimeo/psalm": "^5.0" - }, - "suggest": { - "laminas/laminas-cache": "Laminas\\Cache component", - "laminas/laminas-db": "Laminas\\Db component", - "laminas/laminas-http": "Laminas\\Http component", - "laminas/laminas-servicemanager": "Laminas\\ServiceManager component", - "laminas/laminas-validator": "Laminas\\Validator component", - "mongodb/mongodb": "If you want to use the MongoDB session save handler" - }, - "type": "library", - "extra": { - "laminas": { - "component": "Laminas\\Session", - "config-provider": "Laminas\\Session\\ConfigProvider" - } - }, - "autoload": { - "psr-4": { - "Laminas\\Session\\": "src/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "BSD-3-Clause" - ], - "description": "Object-oriented interface to PHP sessions and storage", - "homepage": "https://laminas.dev", - "keywords": [ - "laminas", - "session" - ], - "support": { - "chat": "https://laminas.dev/chat", - "docs": "https://docs.laminas.dev/laminas-session/", - "forum": "https://discourse.laminas.dev", - "issues": "https://github.com/laminas/laminas-session/issues", - "rss": "https://github.com/laminas/laminas-session/releases.atom", - "source": "https://github.com/laminas/laminas-session" - }, - "funding": [ - { - "url": "https://funding.communitybridge.org/projects/laminas-project", - "type": "community_bridge" - } - ], - "time": "2022-12-04T11:15:36+00:00" - }, { "name": "laminas/laminas-uri", "version": "2.11.0", @@ -5275,6 +5043,89 @@ ], "time": "2023-01-26T09:26:14+00:00" }, + { + "name": "symfony/polyfill-mbstring", + "version": "v1.28.0", + "source": { + "type": "git", + "url": "https://github.com/symfony/polyfill-mbstring.git", + "reference": "42292d99c55abe617799667f454222c54c60e229" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/symfony/polyfill-mbstring/zipball/42292d99c55abe617799667f454222c54c60e229", + "reference": "42292d99c55abe617799667f454222c54c60e229", + "shasum": "" + }, + "require": { + "php": ">=7.1" + }, + "provide": { + "ext-mbstring": "*" + }, + "suggest": { + "ext-mbstring": "For best performance" + }, + "type": "library", + "extra": { + "branch-alias": { + "dev-main": "1.28-dev" + }, + "thanks": { + "name": "symfony/polyfill", + "url": "https://github.com/symfony/polyfill" + } + }, + "autoload": { + "files": [ + "bootstrap.php" + ], + "psr-4": { + "Symfony\\Polyfill\\Mbstring\\": "" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Nicolas Grekas", + "email": "p@tchwork.com" + }, + { + "name": "Symfony Community", + "homepage": "https://symfony.com/contributors" + } + ], + "description": "Symfony polyfill for the Mbstring extension", + "homepage": "https://symfony.com", + "keywords": [ + "compatibility", + "mbstring", + "polyfill", + "portable", + "shim" + ], + "support": { + "source": "https://github.com/symfony/polyfill-mbstring/tree/v1.28.0" + }, + "funding": [ + { + "url": "https://symfony.com/sponsor", + "type": "custom" + }, + { + "url": "https://github.com/fabpot", + "type": "github" + }, + { + "url": "https://tidelift.com/funding/github/packagist/symfony/symfony", + "type": "tidelift" + } + ], + "time": "2023-07-28T09:04:16+00:00" + }, { "name": "symfony/service-contracts", "version": "v2.5.2", From 5cb12c47a7190a28bc2e545990aa17d49abac3ed Mon Sep 17 00:00:00 2001 From: George Steel Date: Wed, 3 Jan 2024 15:17:16 +0000 Subject: [PATCH 41/58] Refresh lock and baseline post merge-up Signed-off-by: George Steel --- composer.lock | 477 ++++++++++++++++++++++++--------------------- psalm-baseline.xml | 248 +++++++++-------------- 2 files changed, 344 insertions(+), 381 deletions(-) diff --git a/composer.lock b/composer.lock index 9d6e326cf..803a4e08c 100644 --- a/composer.lock +++ b/composer.lock @@ -1117,16 +1117,16 @@ }, { "name": "fidry/cpu-core-counter", - "version": "0.5.1", + "version": "1.0.0", "source": { "type": "git", "url": "https://github.com/theofidry/cpu-core-counter.git", - "reference": "b58e5a3933e541dc286cc91fc4f3898bbc6f1623" + "reference": "85193c0b0cb5c47894b5eaec906e946f054e7077" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/theofidry/cpu-core-counter/zipball/b58e5a3933e541dc286cc91fc4f3898bbc6f1623", - "reference": "b58e5a3933e541dc286cc91fc4f3898bbc6f1623", + "url": "https://api.github.com/repos/theofidry/cpu-core-counter/zipball/85193c0b0cb5c47894b5eaec906e946f054e7077", + "reference": "85193c0b0cb5c47894b5eaec906e946f054e7077", "shasum": "" }, "require": { @@ -1134,13 +1134,13 @@ }, "require-dev": { "fidry/makefile": "^0.2.0", + "fidry/php-cs-fixer-config": "^1.1.2", "phpstan/extension-installer": "^1.2.0", "phpstan/phpstan": "^1.9.2", "phpstan/phpstan-deprecation-rules": "^1.0.0", "phpstan/phpstan-phpunit": "^1.2.2", "phpstan/phpstan-strict-rules": "^1.4.4", - "phpunit/phpunit": "^9.5.26 || ^8.5.31", - "theofidry/php-cs-fixer-config": "^1.0", + "phpunit/phpunit": "^8.5.31 || ^9.5.26", "webmozarts/strict-phpunit": "^7.5" }, "type": "library", @@ -1166,7 +1166,7 @@ ], "support": { "issues": "https://github.com/theofidry/cpu-core-counter/issues", - "source": "https://github.com/theofidry/cpu-core-counter/tree/0.5.1" + "source": "https://github.com/theofidry/cpu-core-counter/tree/1.0.0" }, "funding": [ { @@ -1174,42 +1174,42 @@ "type": "github" } ], - "time": "2022-12-24T12:35:10+00:00" + "time": "2023-09-17T21:38:23+00:00" }, { "name": "laminas/laminas-authentication", - "version": "2.15.0", + "version": "2.16.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-authentication.git", - "reference": "9036ae55a84862b16f8631460f90eeea6c19c54e" + "reference": "755b30a37de0f8649bad86dfdc46a0d57cb0d70f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-authentication/zipball/9036ae55a84862b16f8631460f90eeea6c19c54e", - "reference": "9036ae55a84862b16f8631460f90eeea6c19c54e", + "url": "https://api.github.com/repos/laminas/laminas-authentication/zipball/755b30a37de0f8649bad86dfdc46a0d57cb0d70f", + "reference": "755b30a37de0f8649bad86dfdc46a0d57cb0d70f", "shasum": "" }, "require": { "laminas/laminas-stdlib": "^3.6.0", - "php": "~8.0.0 || ~8.1.0 || ~8.2.0" + "php": "~8.1.0 || ~8.2.0 || ~8.3.0" }, "conflict": { "zendframework/zend-authentication": "*" }, "require-dev": { "laminas/laminas-coding-standard": "~2.4.0", - "laminas/laminas-crypt": "^2.6.0 || ^3.9.0", - "laminas/laminas-db": "^2.15.0", - "laminas/laminas-http": "^2.17.0", - "laminas/laminas-ldap": "^2.16", - "laminas/laminas-session": "^2.13.0", + "laminas/laminas-crypt": "^2.6.0 || ^3.10.0", + "laminas/laminas-db": "^2.18.0", + "laminas/laminas-http": "^2.18.0", + "laminas/laminas-ldap": "^2.17", + "laminas/laminas-session": "^2.16.0", "laminas/laminas-uri": "^2.10.0", - "laminas/laminas-validator": "^2.26.0", - "phpunit/phpunit": "^9.5.25", + "laminas/laminas-validator": "^2.30.1", + "phpunit/phpunit": "^9.6.13", "psalm/plugin-phpunit": "^0.17.0", - "squizlabs/php_codesniffer": "^3.7.1", - "vimeo/psalm": "^4.29.0" + "squizlabs/php_codesniffer": "^3.7.2", + "vimeo/psalm": "^4.30.0" }, "suggest": { "laminas/laminas-crypt": "Laminas\\Crypt component", @@ -1250,7 +1250,7 @@ "type": "community_bridge" } ], - "time": "2023-07-12T08:21:19+00:00" + "time": "2023-11-06T09:32:35+00:00" }, { "name": "laminas/laminas-coding-standard", @@ -1602,41 +1602,41 @@ }, { "name": "laminas/laminas-i18n", - "version": "2.23.1", + "version": "2.25.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-i18n.git", - "reference": "970a2775732d56b89434ec283577096887e68167" + "reference": "4b6df8501bfe96648dadaf8de681cbbaea906e04" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-i18n/zipball/970a2775732d56b89434ec283577096887e68167", - "reference": "970a2775732d56b89434ec283577096887e68167", + "url": "https://api.github.com/repos/laminas/laminas-i18n/zipball/4b6df8501bfe96648dadaf8de681cbbaea906e04", + "reference": "4b6df8501bfe96648dadaf8de681cbbaea906e04", "shasum": "" }, "require": { "ext-intl": "*", "laminas/laminas-servicemanager": "^3.21.0", "laminas/laminas-stdlib": "^3.0", - "php": "~8.1.0 || ~8.2.0" + "php": "~8.1.0 || ~8.2.0 || ~8.3.0" }, "conflict": { "laminas/laminas-view": "<2.20.0", "zendframework/zend-i18n": "*" }, "require-dev": { - "laminas/laminas-cache": "^3.10.1", - "laminas/laminas-cache-storage-adapter-memory": "^2.2.0", + "laminas/laminas-cache": "^3.11.0", + "laminas/laminas-cache-storage-adapter-memory": "^2.3.0", "laminas/laminas-cache-storage-deprecated-factory": "^1.1", "laminas/laminas-coding-standard": "~2.5.0", - "laminas/laminas-config": "^3.8.0", - "laminas/laminas-eventmanager": "^3.10", - "laminas/laminas-filter": "^2.31", - "laminas/laminas-validator": "^2.30.1", - "laminas/laminas-view": "^2.27", - "phpunit/phpunit": "^10.1.3", + "laminas/laminas-config": "^3.9.0", + "laminas/laminas-eventmanager": "^3.12", + "laminas/laminas-filter": "^2.33", + "laminas/laminas-validator": "^2.41", + "laminas/laminas-view": "^2.32", + "phpunit/phpunit": "^10.4.2", "psalm/plugin-phpunit": "^0.18.4", - "vimeo/psalm": "^5.11" + "vimeo/psalm": "^5.15.0" }, "suggest": { "laminas/laminas-cache": "You should install this package to cache the translations", @@ -1683,7 +1683,7 @@ "type": "community_bridge" } ], - "time": "2023-10-09T12:00:55+00:00" + "time": "2023-12-22T15:51:21+00:00" }, { "name": "laminas/laminas-loader", @@ -1815,16 +1815,16 @@ }, { "name": "laminas/laminas-mvc", - "version": "3.6.1", + "version": "3.7.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-mvc.git", - "reference": "f12e801c31c04a4b35017354ff84070f5573879f" + "reference": "3f65447addf487189000e54dc1525cd952951da4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-mvc/zipball/f12e801c31c04a4b35017354ff84070f5573879f", - "reference": "f12e801c31c04a4b35017354ff84070f5573879f", + "url": "https://api.github.com/repos/laminas/laminas-mvc/zipball/3f65447addf487189000e54dc1525cd952951da4", + "reference": "3f65447addf487189000e54dc1525cd952951da4", "shasum": "" }, "require": { @@ -1836,17 +1836,17 @@ "laminas/laminas-servicemanager": "^3.20.0", "laminas/laminas-stdlib": "^3.6", "laminas/laminas-view": "^2.14", - "php": "~8.0.0 || ~8.1.0 || ~8.2.0" + "php": "~8.1.0 || ~8.2.0 || ~8.3.0" }, "conflict": { "zendframework/zend-mvc": "*" }, "require-dev": { - "laminas/laminas-coding-standard": "^2.4.0", - "laminas/laminas-json": "^3.3", - "phpspec/prophecy": "^1.15.0", - "phpspec/prophecy-phpunit": "^2.0.1", - "phpunit/phpunit": "^9.5.25", + "laminas/laminas-coding-standard": "^2.5.0", + "laminas/laminas-json": "^3.6", + "phpspec/prophecy": "^1.17.0", + "phpspec/prophecy-phpunit": "^2.0.2", + "phpunit/phpunit": "^9.6.13", "webmozart/assert": "^1.11" }, "suggest": { @@ -1892,20 +1892,20 @@ "type": "community_bridge" } ], - "time": "2023-03-15T10:21:03+00:00" + "time": "2023-11-14T09:44:53+00:00" }, { "name": "laminas/laminas-mvc-i18n", - "version": "1.7.0", + "version": "1.8.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-mvc-i18n.git", - "reference": "571f3e34afbff14351677c450f872a0dd19f9d28" + "reference": "669a00f36dd9fba8ec95516fe4afde7c4d8b8faa" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-mvc-i18n/zipball/571f3e34afbff14351677c450f872a0dd19f9d28", - "reference": "571f3e34afbff14351677c450f872a0dd19f9d28", + "url": "https://api.github.com/repos/laminas/laminas-mvc-i18n/zipball/669a00f36dd9fba8ec95516fe4afde7c4d8b8faa", + "reference": "669a00f36dd9fba8ec95516fe4afde7c4d8b8faa", "shasum": "" }, "require": { @@ -1916,7 +1916,7 @@ "laminas/laminas-servicemanager": "^3.15.1", "laminas/laminas-stdlib": "^3.10.1", "laminas/laminas-validator": "^2.19.0", - "php": "~8.0.0 || ~8.1.0 || ~8.2.0" + "php": "~8.1.0 || ~8.2.0 || ~8.3.0" }, "conflict": { "laminas/laminas-mvc": "<3.0.0", @@ -1924,11 +1924,11 @@ "zendframework/zend-mvc-i18n": "*" }, "require-dev": { - "laminas/laminas-coding-standard": "~2.4.0", - "phpspec/prophecy-phpunit": "^2.0.1", - "phpunit/phpunit": "^9.5.26", - "psalm/plugin-phpunit": "^0.18.0", - "vimeo/psalm": "^5.0.0" + "laminas/laminas-coding-standard": "~2.5.0", + "phpspec/prophecy-phpunit": "^2.0.2", + "phpunit/phpunit": "^9.6.13", + "psalm/plugin-phpunit": "^0.18.4", + "vimeo/psalm": "^5.15" }, "suggest": { "laminas/laminas-cache": "To enable caching of translation strings" @@ -1970,43 +1970,43 @@ "type": "community_bridge" } ], - "time": "2022-12-02T15:45:50+00:00" + "time": "2023-11-06T09:31:01+00:00" }, { "name": "laminas/laminas-navigation", - "version": "2.18.1", + "version": "2.19.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-navigation.git", - "reference": "f685f8b34db462d84617c5ad440f9f273e2558f4" + "reference": "9d212fb17dbb2da4172a7248a67483ebe38ad3a7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-navigation/zipball/f685f8b34db462d84617c5ad440f9f273e2558f4", - "reference": "f685f8b34db462d84617c5ad440f9f273e2558f4", + "url": "https://api.github.com/repos/laminas/laminas-navigation/zipball/9d212fb17dbb2da4172a7248a67483ebe38ad3a7", + "reference": "9d212fb17dbb2da4172a7248a67483ebe38ad3a7", "shasum": "" }, "require": { "laminas/laminas-stdlib": "^2.7 || ^3.0", - "php": "~8.0.0 || ~8.1.0 || ~8.2.0" + "php": "~8.1.0 || ~8.2.0 || ~8.3.0" }, "conflict": { "zendframework/zend-navigation": "*" }, "require-dev": { - "laminas/laminas-coding-standard": "~2.4.0", + "laminas/laminas-coding-standard": "~2.5.0", "laminas/laminas-config": "^3.8.0", "laminas/laminas-http": "^2.18", "laminas/laminas-i18n": "^2.21", "laminas/laminas-mvc": "^3.6", "laminas/laminas-permissions-acl": "^2.13", - "laminas/laminas-router": "^3.11", + "laminas/laminas-router": "^3.11.1", "laminas/laminas-servicemanager": "^3.20", "laminas/laminas-uri": "^2.10.0", - "laminas/laminas-view": "^2.25", - "phpunit/phpunit": "^9.5.26", + "laminas/laminas-view": "^2.26", + "phpunit/phpunit": "^9.5.28", "psalm/plugin-phpunit": "^0.18.4", - "vimeo/psalm": "^5.1" + "vimeo/psalm": "^5.6" }, "suggest": { "laminas/laminas-config": "^3.7, to provide page configuration (optional, as arrays and Traversables are also allowed)", @@ -2051,41 +2051,41 @@ "type": "community_bridge" } ], - "time": "2022-12-06T18:03:48+00:00" + "time": "2023-11-14T21:49:15+00:00" }, { "name": "laminas/laminas-paginator", - "version": "2.17.0", + "version": "2.18.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-paginator.git", - "reference": "d0fca60a32656fe095045d76af7ad3a3bfc297f9" + "reference": "caacfd2625bf354be32888dd55767c893b89d38f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-paginator/zipball/d0fca60a32656fe095045d76af7ad3a3bfc297f9", - "reference": "d0fca60a32656fe095045d76af7ad3a3bfc297f9", + "url": "https://api.github.com/repos/laminas/laminas-paginator/zipball/caacfd2625bf354be32888dd55767c893b89d38f", + "reference": "caacfd2625bf354be32888dd55767c893b89d38f", "shasum": "" }, "require": { "ext-json": "*", "laminas/laminas-stdlib": "^3.10.1", - "php": "~8.0.0 || ~8.1.0 || ~8.2.0" + "php": "~8.1.0 || ~8.2.0 || ~8.3.0" }, "conflict": { "zendframework/zend-paginator": "*" }, "require-dev": { - "laminas/laminas-cache": "^3.6.0", + "laminas/laminas-cache": "^3.9", "laminas/laminas-cache-storage-adapter-memory": "^2.2.0", "laminas/laminas-coding-standard": "^2.4.0", "laminas/laminas-config": "^3.8.0", - "laminas/laminas-filter": "^2.23.0", - "laminas/laminas-servicemanager": "^3.19.0", - "laminas/laminas-view": "^2.24.0", - "phpunit/phpunit": "^9.5.25", - "psalm/plugin-phpunit": "^0.18.0", - "vimeo/psalm": "^5.0.0" + "laminas/laminas-filter": "^2.30", + "laminas/laminas-servicemanager": "^3.22", + "laminas/laminas-view": "^2.25", + "phpunit/phpunit": "^9.5.27", + "psalm/plugin-phpunit": "^0.18.4", + "vimeo/psalm": "^5.4" }, "suggest": { "laminas/laminas-cache": "Laminas\\Cache component to support cache features", @@ -2130,7 +2130,7 @@ "type": "community_bridge" } ], - "time": "2022-12-05T16:02:38+00:00" + "time": "2023-11-08T15:42:20+00:00" }, { "name": "laminas/laminas-permissions-acl", @@ -2327,16 +2327,16 @@ }, { "name": "laminas/laminas-validator", - "version": "2.41.0", + "version": "2.46.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-validator.git", - "reference": "ca27df621e12cbd4c138dab7abf3e7e5692c582c" + "reference": "98330256f8d8a1357a93f6f7f1a987036aff6329" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-validator/zipball/ca27df621e12cbd4c138dab7abf3e7e5692c582c", - "reference": "ca27df621e12cbd4c138dab7abf3e7e5692c582c", + "url": "https://api.github.com/repos/laminas/laminas-validator/zipball/98330256f8d8a1357a93f6f7f1a987036aff6329", + "reference": "98330256f8d8a1357a93f6f7f1a987036aff6329", "shasum": "" }, "require": { @@ -2351,15 +2351,15 @@ "require-dev": { "laminas/laminas-coding-standard": "^2.5", "laminas/laminas-db": "^2.18", - "laminas/laminas-filter": "^2.32", - "laminas/laminas-i18n": "^2.23", - "laminas/laminas-session": "^2.16", - "laminas/laminas-uri": "^2.10.0", - "phpunit/phpunit": "^10.3.3", + "laminas/laminas-filter": "^2.33", + "laminas/laminas-i18n": "^2.24.1", + "laminas/laminas-session": "^2.17", + "laminas/laminas-uri": "^2.11.0", + "phpunit/phpunit": "^10.5.2", "psalm/plugin-phpunit": "^0.18.4", - "psr/http-client": "^1.0.2", + "psr/http-client": "^1.0.3", "psr/http-factory": "^1.0.2", - "vimeo/psalm": "^5.15" + "vimeo/psalm": "^5.17" }, "suggest": { "laminas/laminas-db": "Laminas\\Db component, required by the (No)RecordExists validator", @@ -2407,7 +2407,7 @@ "type": "community_bridge" } ], - "time": "2023-10-30T08:22:19+00:00" + "time": "2024-01-03T12:43:04+00:00" }, { "name": "myclabs/deep-copy", @@ -2521,16 +2521,16 @@ }, { "name": "nikic/php-parser", - "version": "v4.17.1", + "version": "v4.18.0", "source": { "type": "git", "url": "https://github.com/nikic/PHP-Parser.git", - "reference": "a6303e50c90c355c7eeee2c4a8b27fe8dc8fef1d" + "reference": "1bcbb2179f97633e98bbbc87044ee2611c7d7999" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/a6303e50c90c355c7eeee2c4a8b27fe8dc8fef1d", - "reference": "a6303e50c90c355c7eeee2c4a8b27fe8dc8fef1d", + "url": "https://api.github.com/repos/nikic/PHP-Parser/zipball/1bcbb2179f97633e98bbbc87044ee2611c7d7999", + "reference": "1bcbb2179f97633e98bbbc87044ee2611c7d7999", "shasum": "" }, "require": { @@ -2571,9 +2571,9 @@ ], "support": { "issues": "https://github.com/nikic/PHP-Parser/issues", - "source": "https://github.com/nikic/PHP-Parser/tree/v4.17.1" + "source": "https://github.com/nikic/PHP-Parser/tree/v4.18.0" }, - "time": "2023-08-13T19:53:39+00:00" + "time": "2023-12-10T21:03:43+00:00" }, { "name": "phar-io/manifest", @@ -2897,23 +2897,23 @@ }, { "name": "phpunit/php-code-coverage", - "version": "10.1.7", + "version": "10.1.11", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/php-code-coverage.git", - "reference": "355324ca4980b8916c18b9db29f3ef484078f26e" + "reference": "78c3b7625965c2513ee96569a4dbb62601784145" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/355324ca4980b8916c18b9db29f3ef484078f26e", - "reference": "355324ca4980b8916c18b9db29f3ef484078f26e", + "url": "https://api.github.com/repos/sebastianbergmann/php-code-coverage/zipball/78c3b7625965c2513ee96569a4dbb62601784145", + "reference": "78c3b7625965c2513ee96569a4dbb62601784145", "shasum": "" }, "require": { "ext-dom": "*", "ext-libxml": "*", "ext-xmlwriter": "*", - "nikic/php-parser": "^4.15", + "nikic/php-parser": "^4.18 || ^5.0", "php": ">=8.1", "phpunit/php-file-iterator": "^4.0", "phpunit/php-text-template": "^3.0", @@ -2963,7 +2963,7 @@ "support": { "issues": "https://github.com/sebastianbergmann/php-code-coverage/issues", "security": "https://github.com/sebastianbergmann/php-code-coverage/security/policy", - "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/10.1.7" + "source": "https://github.com/sebastianbergmann/php-code-coverage/tree/10.1.11" }, "funding": [ { @@ -2971,7 +2971,7 @@ "type": "github" } ], - "time": "2023-10-04T15:34:17+00:00" + "time": "2023-12-21T15:38:30+00:00" }, { "name": "phpunit/php-file-iterator", @@ -3218,16 +3218,16 @@ }, { "name": "phpunit/phpunit", - "version": "10.4.2", + "version": "10.5.5", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "cacd8b9dd224efa8eb28beb69004126c7ca1a1a1" + "reference": "ed21115d505b4b4f7dc7b5651464e19a2c7f7856" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/cacd8b9dd224efa8eb28beb69004126c7ca1a1a1", - "reference": "cacd8b9dd224efa8eb28beb69004126c7ca1a1a1", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/ed21115d505b4b4f7dc7b5651464e19a2c7f7856", + "reference": "ed21115d505b4b4f7dc7b5651464e19a2c7f7856", "shasum": "" }, "require": { @@ -3267,7 +3267,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "10.4-dev" + "dev-main": "10.5-dev" } }, "autoload": { @@ -3299,7 +3299,7 @@ "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", "security": "https://github.com/sebastianbergmann/phpunit/security/policy", - "source": "https://github.com/sebastianbergmann/phpunit/tree/10.4.2" + "source": "https://github.com/sebastianbergmann/phpunit/tree/10.5.5" }, "funding": [ { @@ -3315,7 +3315,7 @@ "type": "tidelift" } ], - "time": "2023-10-26T07:21:45+00:00" + "time": "2023-12-27T15:13:52+00:00" }, { "name": "psalm/plugin-phpunit", @@ -3726,20 +3726,20 @@ }, { "name": "sebastian/complexity", - "version": "3.1.0", + "version": "3.2.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/complexity.git", - "reference": "68cfb347a44871f01e33ab0ef8215966432f6957" + "reference": "68ff824baeae169ec9f2137158ee529584553799" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/68cfb347a44871f01e33ab0ef8215966432f6957", - "reference": "68cfb347a44871f01e33ab0ef8215966432f6957", + "url": "https://api.github.com/repos/sebastianbergmann/complexity/zipball/68ff824baeae169ec9f2137158ee529584553799", + "reference": "68ff824baeae169ec9f2137158ee529584553799", "shasum": "" }, "require": { - "nikic/php-parser": "^4.10", + "nikic/php-parser": "^4.18 || ^5.0", "php": ">=8.1" }, "require-dev": { @@ -3748,7 +3748,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "3.1-dev" + "dev-main": "3.2-dev" } }, "autoload": { @@ -3772,7 +3772,7 @@ "support": { "issues": "https://github.com/sebastianbergmann/complexity/issues", "security": "https://github.com/sebastianbergmann/complexity/security/policy", - "source": "https://github.com/sebastianbergmann/complexity/tree/3.1.0" + "source": "https://github.com/sebastianbergmann/complexity/tree/3.2.0" }, "funding": [ { @@ -3780,20 +3780,20 @@ "type": "github" } ], - "time": "2023-09-28T11:50:59+00:00" + "time": "2023-12-21T08:37:17+00:00" }, { "name": "sebastian/diff", - "version": "5.0.3", + "version": "5.1.0", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/diff.git", - "reference": "912dc2fbe3e3c1e7873313cc801b100b6c68c87b" + "reference": "fbf413a49e54f6b9b17e12d900ac7f6101591b7f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/912dc2fbe3e3c1e7873313cc801b100b6c68c87b", - "reference": "912dc2fbe3e3c1e7873313cc801b100b6c68c87b", + "url": "https://api.github.com/repos/sebastianbergmann/diff/zipball/fbf413a49e54f6b9b17e12d900ac7f6101591b7f", + "reference": "fbf413a49e54f6b9b17e12d900ac7f6101591b7f", "shasum": "" }, "require": { @@ -3806,7 +3806,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "5.0-dev" + "dev-main": "5.1-dev" } }, "autoload": { @@ -3839,7 +3839,7 @@ "support": { "issues": "https://github.com/sebastianbergmann/diff/issues", "security": "https://github.com/sebastianbergmann/diff/security/policy", - "source": "https://github.com/sebastianbergmann/diff/tree/5.0.3" + "source": "https://github.com/sebastianbergmann/diff/tree/5.1.0" }, "funding": [ { @@ -3847,7 +3847,7 @@ "type": "github" } ], - "time": "2023-05-01T07:48:21+00:00" + "time": "2023-12-22T10:55:06+00:00" }, { "name": "sebastian/environment", @@ -4055,20 +4055,20 @@ }, { "name": "sebastian/lines-of-code", - "version": "2.0.1", + "version": "2.0.2", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/lines-of-code.git", - "reference": "649e40d279e243d985aa8fb6e74dd5bb28dc185d" + "reference": "856e7f6a75a84e339195d48c556f23be2ebf75d0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/lines-of-code/zipball/649e40d279e243d985aa8fb6e74dd5bb28dc185d", - "reference": "649e40d279e243d985aa8fb6e74dd5bb28dc185d", + "url": "https://api.github.com/repos/sebastianbergmann/lines-of-code/zipball/856e7f6a75a84e339195d48c556f23be2ebf75d0", + "reference": "856e7f6a75a84e339195d48c556f23be2ebf75d0", "shasum": "" }, "require": { - "nikic/php-parser": "^4.10", + "nikic/php-parser": "^4.18 || ^5.0", "php": ">=8.1" }, "require-dev": { @@ -4101,7 +4101,7 @@ "support": { "issues": "https://github.com/sebastianbergmann/lines-of-code/issues", "security": "https://github.com/sebastianbergmann/lines-of-code/security/policy", - "source": "https://github.com/sebastianbergmann/lines-of-code/tree/2.0.1" + "source": "https://github.com/sebastianbergmann/lines-of-code/tree/2.0.2" }, "funding": [ { @@ -4109,7 +4109,7 @@ "type": "github" } ], - "time": "2023-08-31T09:25:50+00:00" + "time": "2023-12-21T08:38:20+00:00" }, { "name": "sebastian/object-enumerator", @@ -4458,16 +4458,16 @@ }, { "name": "spatie/array-to-xml", - "version": "3.2.0", + "version": "3.2.2", "source": { "type": "git", "url": "https://github.com/spatie/array-to-xml.git", - "reference": "f9ab39c808500c347d5a8b6b13310bd5221e39e7" + "reference": "96be97e664c87613121d073ea39af4c74e57a7f8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/spatie/array-to-xml/zipball/f9ab39c808500c347d5a8b6b13310bd5221e39e7", - "reference": "f9ab39c808500c347d5a8b6b13310bd5221e39e7", + "url": "https://api.github.com/repos/spatie/array-to-xml/zipball/96be97e664c87613121d073ea39af4c74e57a7f8", + "reference": "96be97e664c87613121d073ea39af4c74e57a7f8", "shasum": "" }, "require": { @@ -4505,7 +4505,7 @@ "xml" ], "support": { - "source": "https://github.com/spatie/array-to-xml/tree/3.2.0" + "source": "https://github.com/spatie/array-to-xml/tree/3.2.2" }, "funding": [ { @@ -4517,20 +4517,20 @@ "type": "github" } ], - "time": "2023-07-19T18:30:26+00:00" + "time": "2023-11-14T14:08:51+00:00" }, { "name": "squizlabs/php_codesniffer", - "version": "3.7.2", + "version": "3.8.0", "source": { "type": "git", - "url": "https://github.com/squizlabs/PHP_CodeSniffer.git", - "reference": "ed8e00df0a83aa96acf703f8c2979ff33341f879" + "url": "https://github.com/PHPCSStandards/PHP_CodeSniffer.git", + "reference": "5805f7a4e4958dbb5e944ef1e6edae0a303765e7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/ed8e00df0a83aa96acf703f8c2979ff33341f879", - "reference": "ed8e00df0a83aa96acf703f8c2979ff33341f879", + "url": "https://api.github.com/repos/PHPCSStandards/PHP_CodeSniffer/zipball/5805f7a4e4958dbb5e944ef1e6edae0a303765e7", + "reference": "5805f7a4e4958dbb5e944ef1e6edae0a303765e7", "shasum": "" }, "require": { @@ -4540,7 +4540,7 @@ "php": ">=5.4.0" }, "require-dev": { - "phpunit/phpunit": "^4.0 || ^5.0 || ^6.0 || ^7.0" + "phpunit/phpunit": "^4.0 || ^5.0 || ^6.0 || ^7.0 || ^8.0 || ^9.0" }, "bin": [ "bin/phpcs", @@ -4559,35 +4559,58 @@ "authors": [ { "name": "Greg Sherwood", - "role": "lead" + "role": "Former lead" + }, + { + "name": "Juliette Reinders Folmer", + "role": "Current lead" + }, + { + "name": "Contributors", + "homepage": "https://github.com/PHPCSStandards/PHP_CodeSniffer/graphs/contributors" } ], "description": "PHP_CodeSniffer tokenizes PHP, JavaScript and CSS files and detects violations of a defined set of coding standards.", - "homepage": "https://github.com/squizlabs/PHP_CodeSniffer", + "homepage": "https://github.com/PHPCSStandards/PHP_CodeSniffer", "keywords": [ "phpcs", "standards", "static analysis" ], "support": { - "issues": "https://github.com/squizlabs/PHP_CodeSniffer/issues", - "source": "https://github.com/squizlabs/PHP_CodeSniffer", - "wiki": "https://github.com/squizlabs/PHP_CodeSniffer/wiki" + "issues": "https://github.com/PHPCSStandards/PHP_CodeSniffer/issues", + "security": "https://github.com/PHPCSStandards/PHP_CodeSniffer/security/policy", + "source": "https://github.com/PHPCSStandards/PHP_CodeSniffer", + "wiki": "https://github.com/PHPCSStandards/PHP_CodeSniffer/wiki" }, - "time": "2023-02-22T23:07:41+00:00" + "funding": [ + { + "url": "https://github.com/PHPCSStandards", + "type": "github" + }, + { + "url": "https://github.com/jrfnl", + "type": "github" + }, + { + "url": "https://opencollective.com/php_codesniffer", + "type": "open_collective" + } + ], + "time": "2023-12-08T12:32:31+00:00" }, { "name": "symfony/console", - "version": "v6.3.4", + "version": "v6.4.2", "source": { "type": "git", "url": "https://github.com/symfony/console.git", - "reference": "eca495f2ee845130855ddf1cf18460c38966c8b6" + "reference": "0254811a143e6bc6c8deea08b589a7e68a37f625" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/console/zipball/eca495f2ee845130855ddf1cf18460c38966c8b6", - "reference": "eca495f2ee845130855ddf1cf18460c38966c8b6", + "url": "https://api.github.com/repos/symfony/console/zipball/0254811a143e6bc6c8deea08b589a7e68a37f625", + "reference": "0254811a143e6bc6c8deea08b589a7e68a37f625", "shasum": "" }, "require": { @@ -4595,7 +4618,7 @@ "symfony/deprecation-contracts": "^2.5|^3", "symfony/polyfill-mbstring": "~1.0", "symfony/service-contracts": "^2.5|^3", - "symfony/string": "^5.4|^6.0" + "symfony/string": "^5.4|^6.0|^7.0" }, "conflict": { "symfony/dependency-injection": "<5.4", @@ -4609,12 +4632,16 @@ }, "require-dev": { "psr/log": "^1|^2|^3", - "symfony/config": "^5.4|^6.0", - "symfony/dependency-injection": "^5.4|^6.0", - "symfony/event-dispatcher": "^5.4|^6.0", - "symfony/lock": "^5.4|^6.0", - "symfony/process": "^5.4|^6.0", - "symfony/var-dumper": "^5.4|^6.0" + "symfony/config": "^5.4|^6.0|^7.0", + "symfony/dependency-injection": "^5.4|^6.0|^7.0", + "symfony/event-dispatcher": "^5.4|^6.0|^7.0", + "symfony/http-foundation": "^6.4|^7.0", + "symfony/http-kernel": "^6.4|^7.0", + "symfony/lock": "^5.4|^6.0|^7.0", + "symfony/messenger": "^5.4|^6.0|^7.0", + "symfony/process": "^5.4|^6.0|^7.0", + "symfony/stopwatch": "^5.4|^6.0|^7.0", + "symfony/var-dumper": "^5.4|^6.0|^7.0" }, "type": "library", "autoload": { @@ -4648,7 +4675,7 @@ "terminal" ], "support": { - "source": "https://github.com/symfony/console/tree/v6.3.4" + "source": "https://github.com/symfony/console/tree/v6.4.2" }, "funding": [ { @@ -4664,11 +4691,11 @@ "type": "tidelift" } ], - "time": "2023-08-16T10:10:12+00:00" + "time": "2023-12-10T16:15:48+00:00" }, { "name": "symfony/deprecation-contracts", - "version": "v3.3.0", + "version": "v3.4.0", "source": { "type": "git", "url": "https://github.com/symfony/deprecation-contracts.git", @@ -4715,7 +4742,7 @@ "description": "A generic function and convention to trigger deprecation notices", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/deprecation-contracts/tree/v3.3.0" + "source": "https://github.com/symfony/deprecation-contracts/tree/v3.4.0" }, "funding": [ { @@ -4735,16 +4762,16 @@ }, { "name": "symfony/filesystem", - "version": "v6.3.1", + "version": "v6.4.0", "source": { "type": "git", "url": "https://github.com/symfony/filesystem.git", - "reference": "edd36776956f2a6fcf577edb5b05eb0e3bdc52ae" + "reference": "952a8cb588c3bc6ce76f6023000fb932f16a6e59" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/filesystem/zipball/edd36776956f2a6fcf577edb5b05eb0e3bdc52ae", - "reference": "edd36776956f2a6fcf577edb5b05eb0e3bdc52ae", + "url": "https://api.github.com/repos/symfony/filesystem/zipball/952a8cb588c3bc6ce76f6023000fb932f16a6e59", + "reference": "952a8cb588c3bc6ce76f6023000fb932f16a6e59", "shasum": "" }, "require": { @@ -4778,7 +4805,7 @@ "description": "Provides basic utilities for the filesystem", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/filesystem/tree/v6.3.1" + "source": "https://github.com/symfony/filesystem/tree/v6.4.0" }, "funding": [ { @@ -4794,7 +4821,7 @@ "type": "tidelift" } ], - "time": "2023-06-01T08:30:39+00:00" + "time": "2023-07-26T17:27:13+00:00" }, { "name": "symfony/polyfill-ctype", @@ -5128,33 +5155,29 @@ }, { "name": "symfony/service-contracts", - "version": "v2.5.2", + "version": "v3.4.1", "source": { "type": "git", "url": "https://github.com/symfony/service-contracts.git", - "reference": "4b426aac47d6427cc1a1d0f7e2ac724627f5966c" + "reference": "fe07cbc8d837f60caf7018068e350cc5163681a0" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/service-contracts/zipball/4b426aac47d6427cc1a1d0f7e2ac724627f5966c", - "reference": "4b426aac47d6427cc1a1d0f7e2ac724627f5966c", + "url": "https://api.github.com/repos/symfony/service-contracts/zipball/fe07cbc8d837f60caf7018068e350cc5163681a0", + "reference": "fe07cbc8d837f60caf7018068e350cc5163681a0", "shasum": "" }, "require": { - "php": ">=7.2.5", - "psr/container": "^1.1", - "symfony/deprecation-contracts": "^2.1|^3" + "php": ">=8.1", + "psr/container": "^1.1|^2.0" }, "conflict": { "ext-psr": "<1.1|>=2" }, - "suggest": { - "symfony/service-implementation": "" - }, "type": "library", "extra": { "branch-alias": { - "dev-main": "2.5-dev" + "dev-main": "3.4-dev" }, "thanks": { "name": "symfony/contracts", @@ -5164,7 +5187,10 @@ "autoload": { "psr-4": { "Symfony\\Contracts\\Service\\": "" - } + }, + "exclude-from-classmap": [ + "/Test/" + ] }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -5191,7 +5217,7 @@ "standards" ], "support": { - "source": "https://github.com/symfony/service-contracts/tree/v2.5.2" + "source": "https://github.com/symfony/service-contracts/tree/v3.4.1" }, "funding": [ { @@ -5207,20 +5233,20 @@ "type": "tidelift" } ], - "time": "2022-05-30T19:17:29+00:00" + "time": "2023-12-26T14:02:43+00:00" }, { "name": "symfony/string", - "version": "v6.3.5", + "version": "v6.4.2", "source": { "type": "git", "url": "https://github.com/symfony/string.git", - "reference": "13d76d0fb049051ed12a04bef4f9de8715bea339" + "reference": "7cb80bc10bfcdf6b5492741c0b9357dac66940bc" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/string/zipball/13d76d0fb049051ed12a04bef4f9de8715bea339", - "reference": "13d76d0fb049051ed12a04bef4f9de8715bea339", + "url": "https://api.github.com/repos/symfony/string/zipball/7cb80bc10bfcdf6b5492741c0b9357dac66940bc", + "reference": "7cb80bc10bfcdf6b5492741c0b9357dac66940bc", "shasum": "" }, "require": { @@ -5234,11 +5260,11 @@ "symfony/translation-contracts": "<2.5" }, "require-dev": { - "symfony/error-handler": "^5.4|^6.0", - "symfony/http-client": "^5.4|^6.0", - "symfony/intl": "^6.2", + "symfony/error-handler": "^5.4|^6.0|^7.0", + "symfony/http-client": "^5.4|^6.0|^7.0", + "symfony/intl": "^6.2|^7.0", "symfony/translation-contracts": "^2.5|^3.0", - "symfony/var-exporter": "^5.4|^6.0" + "symfony/var-exporter": "^5.4|^6.0|^7.0" }, "type": "library", "autoload": { @@ -5277,7 +5303,7 @@ "utf8" ], "support": { - "source": "https://github.com/symfony/string/tree/v6.3.5" + "source": "https://github.com/symfony/string/tree/v6.4.2" }, "funding": [ { @@ -5293,20 +5319,20 @@ "type": "tidelift" } ], - "time": "2023-09-18T10:38:32+00:00" + "time": "2023-12-10T16:15:48+00:00" }, { "name": "theseer/tokenizer", - "version": "1.2.1", + "version": "1.2.2", "source": { "type": "git", "url": "https://github.com/theseer/tokenizer.git", - "reference": "34a41e998c2183e22995f158c581e7b5e755ab9e" + "reference": "b2ad5003ca10d4ee50a12da31de12a5774ba6b96" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/theseer/tokenizer/zipball/34a41e998c2183e22995f158c581e7b5e755ab9e", - "reference": "34a41e998c2183e22995f158c581e7b5e755ab9e", + "url": "https://api.github.com/repos/theseer/tokenizer/zipball/b2ad5003ca10d4ee50a12da31de12a5774ba6b96", + "reference": "b2ad5003ca10d4ee50a12da31de12a5774ba6b96", "shasum": "" }, "require": { @@ -5335,7 +5361,7 @@ "description": "A small library for converting tokenized PHP source code into XML and potentially other formats", "support": { "issues": "https://github.com/theseer/tokenizer/issues", - "source": "https://github.com/theseer/tokenizer/tree/1.2.1" + "source": "https://github.com/theseer/tokenizer/tree/1.2.2" }, "funding": [ { @@ -5343,20 +5369,20 @@ "type": "github" } ], - "time": "2021-07-28T10:34:58+00:00" + "time": "2023-11-20T00:12:19+00:00" }, { "name": "vimeo/psalm", - "version": "5.15.0", + "version": "5.18.0", "source": { "type": "git", "url": "https://github.com/vimeo/psalm.git", - "reference": "5c774aca4746caf3d239d9c8cadb9f882ca29352" + "reference": "b113f3ed0259fd6e212d87c3df80eec95a6abf19" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/vimeo/psalm/zipball/5c774aca4746caf3d239d9c8cadb9f882ca29352", - "reference": "5c774aca4746caf3d239d9c8cadb9f882ca29352", + "url": "https://api.github.com/repos/vimeo/psalm/zipball/b113f3ed0259fd6e212d87c3df80eec95a6abf19", + "reference": "b113f3ed0259fd6e212d87c3df80eec95a6abf19", "shasum": "" }, "require": { @@ -5375,14 +5401,14 @@ "ext-tokenizer": "*", "felixfbecker/advanced-json-rpc": "^3.1", "felixfbecker/language-server-protocol": "^1.5.2", - "fidry/cpu-core-counter": "^0.4.1 || ^0.5.1", + "fidry/cpu-core-counter": "^0.4.1 || ^0.5.1 || ^1.0.0", "netresearch/jsonmapper": "^1.0 || ^2.0 || ^3.0 || ^4.0", "nikic/php-parser": "^4.16", "php": "^7.4 || ~8.0.0 || ~8.1.0 || ~8.2.0 || ~8.3.0", "sebastian/diff": "^4.0 || ^5.0", "spatie/array-to-xml": "^2.17.0 || ^3.0", - "symfony/console": "^4.1.6 || ^5.0 || ^6.0", - "symfony/filesystem": "^5.4 || ^6.0" + "symfony/console": "^4.1.6 || ^5.0 || ^6.0 || ^7.0", + "symfony/filesystem": "^5.4 || ^6.0 || ^7.0" }, "conflict": { "nikic/php-parser": "4.17.0" @@ -5404,7 +5430,7 @@ "psalm/plugin-phpunit": "^0.18", "slevomat/coding-standard": "^8.4", "squizlabs/php_codesniffer": "^3.6", - "symfony/process": "^4.4 || ^5.0 || ^6.0" + "symfony/process": "^4.4 || ^5.0 || ^6.0 || ^7.0" }, "suggest": { "ext-curl": "In order to send data to shepherd", @@ -5417,7 +5443,7 @@ "psalm-refactor", "psalter" ], - "type": "library", + "type": "project", "extra": { "branch-alias": { "dev-master": "5.x-dev", @@ -5449,23 +5475,24 @@ "static analysis" ], "support": { + "docs": "https://psalm.dev/docs", "issues": "https://github.com/vimeo/psalm/issues", - "source": "https://github.com/vimeo/psalm/tree/5.15.0" + "source": "https://github.com/vimeo/psalm" }, - "time": "2023-08-20T23:07:30+00:00" + "time": "2023-12-16T09:37:35+00:00" }, { "name": "webimpress/coding-standard", - "version": "1.3.1", + "version": "1.3.2", "source": { "type": "git", "url": "https://github.com/webimpress/coding-standard.git", - "reference": "b26557e2386711ecb74f22718f4b4bde5ddbc899" + "reference": "710f71ac95d36d931e76b47132b599c39abfab11" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/webimpress/coding-standard/zipball/b26557e2386711ecb74f22718f4b4bde5ddbc899", - "reference": "b26557e2386711ecb74f22718f4b4bde5ddbc899", + "url": "https://api.github.com/repos/webimpress/coding-standard/zipball/710f71ac95d36d931e76b47132b599c39abfab11", + "reference": "710f71ac95d36d931e76b47132b599c39abfab11", "shasum": "" }, "require": { @@ -5473,7 +5500,7 @@ "squizlabs/php_codesniffer": "^3.7.2" }, "require-dev": { - "phpunit/phpunit": "^9.6.4" + "phpunit/phpunit": "^9.6.15" }, "type": "phpcodesniffer-standard", "extra": { @@ -5499,7 +5526,7 @@ ], "support": { "issues": "https://github.com/webimpress/coding-standard/issues", - "source": "https://github.com/webimpress/coding-standard/tree/1.3.1" + "source": "https://github.com/webimpress/coding-standard/tree/1.3.2" }, "funding": [ { @@ -5507,7 +5534,7 @@ "type": "github" } ], - "time": "2023-03-09T15:05:18+00:00" + "time": "2023-12-18T07:25:41+00:00" }, { "name": "webimpress/safe-writer", diff --git a/psalm-baseline.xml b/psalm-baseline.xml index 1c86d84ee..f9f7a4e2d 100644 --- a/psalm-baseline.xml +++ b/psalm-baseline.xml @@ -1,5 +1,5 @@ - + $closingBracket @@ -39,9 +39,6 @@ Cycle Cycle - - __toString - Iterator @@ -101,21 +98,18 @@ null === static::$registeredDoctypes - - __toString - registry['doctypes'][$type]]]> - - array - string - getDoctype()]]]> + + registry['doctype']]]> registry['doctypes']]]> - + array + string + $registry @@ -130,9 +124,6 @@ $flag === null - - __toString - $attributes $email @@ -202,9 +193,6 @@ $type $value - - $index - $index view]]> @@ -311,9 +299,6 @@ parent::__call($method, $args) parent::__call($method, $args) - - $index - (bool) $flag @@ -348,20 +333,13 @@ $content $index - - $index - is_string($content) - - is_array($content) - - $content $options @@ -454,9 +432,6 @@ Navigation\Exception\ExceptionInterface - - __toString - $container $container @@ -490,14 +465,11 @@ bool - string $label - $message - $message last()]]> @@ -525,8 +497,6 @@ acl === null && static::$defaultAcl !== null]]> - is_int($maxDepth) - is_int($minDepth) container]]> static::$defaultAcl !== null @@ -659,9 +629,6 @@ null - - $found[0] - (int) $renderFlag @@ -983,7 +950,15 @@ containerClass($value)]]> + + + Container + + + + is_scalar($key) + $this @@ -996,24 +971,25 @@ nextIndex()]]> $this[$key] .= $data + + TKey + max($keys) + 1 int - - __toString - $items - getArrayCopy()]]> - $values $this[$key] max($keys) + + captureKey]]> + (string) $postfix (string) $prefix @@ -1021,9 +997,23 @@ - - __toString - + + $container + containerClass()]]> + + + container]]> + + + ]]> + + + ]]> + |null]]> + + + getContainer()]]> + $return @@ -1159,12 +1149,18 @@ - $reuseMatchedParams + + $params + $reuseMatchedParams + $options + + $reuseMatchedParams + @@ -1174,9 +1170,6 @@ ! $events ! $events - - get - get('EventManager')]]> get('MvcTranslator')]]> @@ -1290,6 +1283,9 @@ + + (array) $nameOrModel + @@ -1299,6 +1295,9 @@ $type + + $values + is_string($nameOrModel) @@ -1307,15 +1306,16 @@ $jsonpCallback - - $nameOrModel - $child $value + + $nameOrModel + $nameOrModel + $childValues $children @@ -1332,11 +1332,14 @@ ! is_object($nameOrModel) jsonpCallback]]> + + $nameOrModel instanceof Traversable + + gettype($helpers) - gettype($variables) __templateResolver->resolve($name, $this)]]> @@ -1348,51 +1351,27 @@ string|Resolver - $__vars __template]]> __template]]> __varsCache)]]> - - $vars[$name] - $vars[$name] - - - $vars[$name] - - - __vars[$key]]]> - __vars[$key]]]> - $includeReturn - $setting __template]]> - __vars]]> $value $value $variablesAsArray[$key] - $vars - $vars - $vars - $vars $vars[$name] - - vars()]]> - string - getArrayCopy new $helpers(new ServiceManager()) - - $setting - __filterChain->filter($this->__content)]]> + __vars[$key]]]> __templateResolver]]> @@ -1409,10 +1388,8 @@ __vars[$key]]]> - __vars[$key]]]> - __vars]]> __vars]]> resolve @@ -1421,7 +1398,6 @@ is_object($helpers) - is_object($variables) __file]]> @@ -1539,15 +1515,13 @@ - - Variables - - $key $value $key + $key + ArrayIterator::class $return @@ -1608,6 +1582,9 @@ $name $name + + $params[$param] + @@ -1615,35 +1592,22 @@ - - $vars - $vars - - - setStrictVars - - - $vars - $vars - $vars - - - varName1]]> - varName1]]> - varName2]]> - varName2]]> - varName3]]> - varName3]]> - varName4]]> - varName4]]> - varName5]]> - addPath + + assertTrue + assertTrue + assertTrue + addPath + + varName2]]> + varName3]]> + varName5]]> + @@ -2240,9 +2204,6 @@ $value $value - - vars()]]> - getVariables()]]> getVariables()]]> @@ -2287,6 +2248,9 @@ addPath addPath + + vars()->message]]> + @@ -2422,6 +2386,13 @@ new stdClass() new stdClass() + + $options + $vars + + + $variables + @@ -2434,21 +2405,12 @@ $foo $return - - assign - assign - assign - assign - assign - getArrayCopy - getArrayCopy - - - renderer->vars()->foo]]> - + + renderer->vars()->foo]]> + $errno $errstr @@ -2569,43 +2531,17 @@ - - $e - $e - $e - $e - $e - $e - $e - $e - $e - $e - $e - content]]> result->content]]> - - $result[] - - - getModel - getModel - getResult - getResult - getResult - getResult - getResult - null - - $e - $e - $e - $e - + + assertIsArray + assertIsArray + assertIsArray + From 43fa45d198ba7b3d243e359b63f301ed9c5cd4d4 Mon Sep 17 00:00:00 2001 From: George Steel Date: Thu, 25 Jan 2024 11:40:52 +0000 Subject: [PATCH 42/58] Minor SA fix Signed-off-by: George Steel --- test/Resolver/TemplatePathStackTest.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/Resolver/TemplatePathStackTest.php b/test/Resolver/TemplatePathStackTest.php index 8d45212e2..4046c8ac3 100644 --- a/test/Resolver/TemplatePathStackTest.php +++ b/test/Resolver/TemplatePathStackTest.php @@ -191,7 +191,7 @@ public function testAllowsSettingOptions($options): void $this->stack->setOptions($options); $this->assertFalse($this->stack->isLfiProtectionOn()); - $this->assertSame($options['default_suffix'], $this->stack->getDefaultSuffix()); + $this->assertSame('php', $this->stack->getDefaultSuffix()); $this->assertEquals(array_reverse($this->paths), $this->stack->getPaths()->toArray()); } From 5a29b47403f37002ae4a0c89fc6798dca68f0c6a Mon Sep 17 00:00:00 2001 From: George Steel Date: Thu, 25 Jan 2024 11:41:14 +0000 Subject: [PATCH 43/58] Refresh lock and baseline post merge-up Signed-off-by: George Steel --- composer.lock | 148 ++++++++++---------- psalm-baseline.xml | 335 +-------------------------------------------- 2 files changed, 77 insertions(+), 406 deletions(-) diff --git a/composer.lock b/composer.lock index 803a4e08c..f5db38f21 100644 --- a/composer.lock +++ b/composer.lock @@ -4,7 +4,7 @@ "Read more about it at https://getcomposer.org/doc/01-basic-usage.md#installing-dependencies", "This file is @generated automatically" ], - "content-hash": "b0c418f8e21dfd1b22c09c160f09f84d", + "content-hash": "dfd16c568b651d75cbf04e3bbdddcdd1", "packages": [ { "name": "laminas/laminas-escaper", @@ -70,16 +70,16 @@ }, { "name": "laminas/laminas-eventmanager", - "version": "3.12.0", + "version": "3.13.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-eventmanager.git", - "reference": "4a576922c00cc7838d60d004a7bd6f5a02c23b57" + "reference": "ce5ba8bde378fca5cb0cd514f01823637215b2f3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-eventmanager/zipball/4a576922c00cc7838d60d004a7bd6f5a02c23b57", - "reference": "4a576922c00cc7838d60d004a7bd6f5a02c23b57", + "url": "https://api.github.com/repos/laminas/laminas-eventmanager/zipball/ce5ba8bde378fca5cb0cd514f01823637215b2f3", + "reference": "ce5ba8bde378fca5cb0cd514f01823637215b2f3", "shasum": "" }, "require": { @@ -91,12 +91,12 @@ }, "require-dev": { "laminas/laminas-coding-standard": "~2.5.0", - "laminas/laminas-stdlib": "^3.17", - "phpbench/phpbench": "^1.2.10", - "phpunit/phpunit": "^10.4.1", + "laminas/laminas-stdlib": "^3.18", + "phpbench/phpbench": "^1.2.15", + "phpunit/phpunit": "^10.5.5", "psalm/plugin-phpunit": "^0.18.4", "psr/container": "^1.1.2 || ^2.0.2", - "vimeo/psalm": "^5.11" + "vimeo/psalm": "^5.18" }, "suggest": { "laminas/laminas-stdlib": "^2.7.3 || ^3.0, to use the FilterChain feature", @@ -134,7 +134,7 @@ "type": "community_bridge" } ], - "time": "2023-10-18T16:36:45+00:00" + "time": "2024-01-03T17:43:50+00:00" }, { "name": "laminas/laminas-json", @@ -289,16 +289,16 @@ }, { "name": "laminas/laminas-stdlib", - "version": "3.18.0", + "version": "3.19.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-stdlib.git", - "reference": "e85b29076c6216e7fc98e72b42dbe1bbc3b95ecf" + "reference": "6a192dd0882b514e45506f533b833b623b78fff3" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-stdlib/zipball/e85b29076c6216e7fc98e72b42dbe1bbc3b95ecf", - "reference": "e85b29076c6216e7fc98e72b42dbe1bbc3b95ecf", + "url": "https://api.github.com/repos/laminas/laminas-stdlib/zipball/6a192dd0882b514e45506f533b833b623b78fff3", + "reference": "6a192dd0882b514e45506f533b833b623b78fff3", "shasum": "" }, "require": { @@ -309,10 +309,10 @@ }, "require-dev": { "laminas/laminas-coding-standard": "^2.5", - "phpbench/phpbench": "^1.2.14", - "phpunit/phpunit": "^10.3.3", + "phpbench/phpbench": "^1.2.15", + "phpunit/phpunit": "^10.5.8", "psalm/plugin-phpunit": "^0.18.4", - "vimeo/psalm": "^5.15.0" + "vimeo/psalm": "^5.20.0" }, "type": "library", "autoload": { @@ -344,7 +344,7 @@ "type": "community_bridge" } ], - "time": "2023-09-19T10:15:21+00:00" + "time": "2024-01-19T12:39:49+00:00" }, { "name": "psr/container", @@ -1458,16 +1458,16 @@ }, { "name": "laminas/laminas-filter", - "version": "2.33.0", + "version": "2.34.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-filter.git", - "reference": "6ad64828d25ec4bdf226ec5096aabb04aa710324" + "reference": "008923542683d853109af5c71b7e9099de76c3e6" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-filter/zipball/6ad64828d25ec4bdf226ec5096aabb04aa710324", - "reference": "6ad64828d25ec4bdf226ec5096aabb04aa710324", + "url": "https://api.github.com/repos/laminas/laminas-filter/zipball/008923542683d853109af5c71b7e9099de76c3e6", + "reference": "008923542683d853109af5c71b7e9099de76c3e6", "shasum": "" }, "require": { @@ -1482,14 +1482,14 @@ }, "require-dev": { "laminas/laminas-coding-standard": "~2.5.0", - "laminas/laminas-crypt": "^3.10", - "laminas/laminas-i18n": "^2.23.1", + "laminas/laminas-crypt": "^3.11", + "laminas/laminas-i18n": "^2.25.0", "laminas/laminas-uri": "^2.11", "pear/archive_tar": "^1.4.14", - "phpunit/phpunit": "^10.4.2", + "phpunit/phpunit": "^10.5.5", "psalm/plugin-phpunit": "^0.18.4", "psr/http-factory": "^1.0.2", - "vimeo/psalm": "^5.15.0" + "vimeo/psalm": "^5.18.0" }, "suggest": { "laminas/laminas-crypt": "Laminas\\Crypt component, for encryption filters", @@ -1533,7 +1533,7 @@ "type": "community_bridge" } ], - "time": "2023-11-03T13:29:10+00:00" + "time": "2024-01-04T11:47:08+00:00" }, { "name": "laminas/laminas-http", @@ -1602,16 +1602,16 @@ }, { "name": "laminas/laminas-i18n", - "version": "2.25.0", + "version": "2.26.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-i18n.git", - "reference": "4b6df8501bfe96648dadaf8de681cbbaea906e04" + "reference": "01738410cb263994d1d192861f642387e7e12ace" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-i18n/zipball/4b6df8501bfe96648dadaf8de681cbbaea906e04", - "reference": "4b6df8501bfe96648dadaf8de681cbbaea906e04", + "url": "https://api.github.com/repos/laminas/laminas-i18n/zipball/01738410cb263994d1d192861f642387e7e12ace", + "reference": "01738410cb263994d1d192861f642387e7e12ace", "shasum": "" }, "require": { @@ -1625,18 +1625,18 @@ "zendframework/zend-i18n": "*" }, "require-dev": { - "laminas/laminas-cache": "^3.11.0", + "laminas/laminas-cache": "^3.12.0", "laminas/laminas-cache-storage-adapter-memory": "^2.3.0", - "laminas/laminas-cache-storage-deprecated-factory": "^1.1", + "laminas/laminas-cache-storage-deprecated-factory": "^1.2", "laminas/laminas-coding-standard": "~2.5.0", "laminas/laminas-config": "^3.9.0", - "laminas/laminas-eventmanager": "^3.12", - "laminas/laminas-filter": "^2.33", - "laminas/laminas-validator": "^2.41", - "laminas/laminas-view": "^2.32", - "phpunit/phpunit": "^10.4.2", + "laminas/laminas-eventmanager": "^3.13", + "laminas/laminas-filter": "^2.34", + "laminas/laminas-validator": "^2.46", + "laminas/laminas-view": "^2.33", + "phpunit/phpunit": "^10.5.5", "psalm/plugin-phpunit": "^0.18.4", - "vimeo/psalm": "^5.15.0" + "vimeo/psalm": "^5.18.0" }, "suggest": { "laminas/laminas-cache": "You should install this package to cache the translations", @@ -1683,7 +1683,7 @@ "type": "community_bridge" } ], - "time": "2023-12-22T15:51:21+00:00" + "time": "2024-01-04T13:49:00+00:00" }, { "name": "laminas/laminas-loader", @@ -1974,16 +1974,16 @@ }, { "name": "laminas/laminas-navigation", - "version": "2.19.0", + "version": "2.19.1", "source": { "type": "git", "url": "https://github.com/laminas/laminas-navigation.git", - "reference": "9d212fb17dbb2da4172a7248a67483ebe38ad3a7" + "reference": "2ef88f68066381698b528be7fdd001723458a479" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-navigation/zipball/9d212fb17dbb2da4172a7248a67483ebe38ad3a7", - "reference": "9d212fb17dbb2da4172a7248a67483ebe38ad3a7", + "url": "https://api.github.com/repos/laminas/laminas-navigation/zipball/2ef88f68066381698b528be7fdd001723458a479", + "reference": "2ef88f68066381698b528be7fdd001723458a479", "shasum": "" }, "require": { @@ -2051,20 +2051,20 @@ "type": "community_bridge" } ], - "time": "2023-11-14T21:49:15+00:00" + "time": "2024-01-10T15:11:10+00:00" }, { "name": "laminas/laminas-paginator", - "version": "2.18.0", + "version": "2.18.1", "source": { "type": "git", "url": "https://github.com/laminas/laminas-paginator.git", - "reference": "caacfd2625bf354be32888dd55767c893b89d38f" + "reference": "6a03499a899fb8ba650594ddf4b4338d4235252a" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-paginator/zipball/caacfd2625bf354be32888dd55767c893b89d38f", - "reference": "caacfd2625bf354be32888dd55767c893b89d38f", + "url": "https://api.github.com/repos/laminas/laminas-paginator/zipball/6a03499a899fb8ba650594ddf4b4338d4235252a", + "reference": "6a03499a899fb8ba650594ddf4b4338d4235252a", "shasum": "" }, "require": { @@ -2130,7 +2130,7 @@ "type": "community_bridge" } ], - "time": "2023-11-08T15:42:20+00:00" + "time": "2024-01-11T11:00:36+00:00" }, { "name": "laminas/laminas-permissions-acl", @@ -2327,16 +2327,16 @@ }, { "name": "laminas/laminas-validator", - "version": "2.46.0", + "version": "2.47.0", "source": { "type": "git", "url": "https://github.com/laminas/laminas-validator.git", - "reference": "98330256f8d8a1357a93f6f7f1a987036aff6329" + "reference": "5c3fc8c4f1263cda5c5f14aed874fdadd5b90bbd" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/laminas/laminas-validator/zipball/98330256f8d8a1357a93f6f7f1a987036aff6329", - "reference": "98330256f8d8a1357a93f6f7f1a987036aff6329", + "url": "https://api.github.com/repos/laminas/laminas-validator/zipball/5c3fc8c4f1263cda5c5f14aed874fdadd5b90bbd", + "reference": "5c3fc8c4f1263cda5c5f14aed874fdadd5b90bbd", "shasum": "" }, "require": { @@ -2407,7 +2407,7 @@ "type": "community_bridge" } ], - "time": "2024-01-03T12:43:04+00:00" + "time": "2024-01-17T11:31:50+00:00" }, { "name": "myclabs/deep-copy", @@ -3218,16 +3218,16 @@ }, { "name": "phpunit/phpunit", - "version": "10.5.5", + "version": "10.5.9", "source": { "type": "git", "url": "https://github.com/sebastianbergmann/phpunit.git", - "reference": "ed21115d505b4b4f7dc7b5651464e19a2c7f7856" + "reference": "0bd663704f0165c9e76fe4f06ffa6a1ca727fdbe" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/ed21115d505b4b4f7dc7b5651464e19a2c7f7856", - "reference": "ed21115d505b4b4f7dc7b5651464e19a2c7f7856", + "url": "https://api.github.com/repos/sebastianbergmann/phpunit/zipball/0bd663704f0165c9e76fe4f06ffa6a1ca727fdbe", + "reference": "0bd663704f0165c9e76fe4f06ffa6a1ca727fdbe", "shasum": "" }, "require": { @@ -3299,7 +3299,7 @@ "support": { "issues": "https://github.com/sebastianbergmann/phpunit/issues", "security": "https://github.com/sebastianbergmann/phpunit/security/policy", - "source": "https://github.com/sebastianbergmann/phpunit/tree/10.5.5" + "source": "https://github.com/sebastianbergmann/phpunit/tree/10.5.9" }, "funding": [ { @@ -3315,7 +3315,7 @@ "type": "tidelift" } ], - "time": "2023-12-27T15:13:52+00:00" + "time": "2024-01-22T14:35:40+00:00" }, { "name": "psalm/plugin-phpunit", @@ -4521,16 +4521,16 @@ }, { "name": "squizlabs/php_codesniffer", - "version": "3.8.0", + "version": "3.8.1", "source": { "type": "git", "url": "https://github.com/PHPCSStandards/PHP_CodeSniffer.git", - "reference": "5805f7a4e4958dbb5e944ef1e6edae0a303765e7" + "reference": "14f5fff1e64118595db5408e946f3a22c75807f7" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/PHPCSStandards/PHP_CodeSniffer/zipball/5805f7a4e4958dbb5e944ef1e6edae0a303765e7", - "reference": "5805f7a4e4958dbb5e944ef1e6edae0a303765e7", + "url": "https://api.github.com/repos/PHPCSStandards/PHP_CodeSniffer/zipball/14f5fff1e64118595db5408e946f3a22c75807f7", + "reference": "14f5fff1e64118595db5408e946f3a22c75807f7", "shasum": "" }, "require": { @@ -4540,11 +4540,11 @@ "php": ">=5.4.0" }, "require-dev": { - "phpunit/phpunit": "^4.0 || ^5.0 || ^6.0 || ^7.0 || ^8.0 || ^9.0" + "phpunit/phpunit": "^4.0 || ^5.0 || ^6.0 || ^7.0 || ^8.0 || ^9.3.4" }, "bin": [ - "bin/phpcs", - "bin/phpcbf" + "bin/phpcbf", + "bin/phpcs" ], "type": "library", "extra": { @@ -4597,7 +4597,7 @@ "type": "open_collective" } ], - "time": "2023-12-08T12:32:31+00:00" + "time": "2024-01-11T20:47:48+00:00" }, { "name": "symfony/console", @@ -5373,16 +5373,16 @@ }, { "name": "vimeo/psalm", - "version": "5.18.0", + "version": "5.20.0", "source": { "type": "git", "url": "https://github.com/vimeo/psalm.git", - "reference": "b113f3ed0259fd6e212d87c3df80eec95a6abf19" + "reference": "3f284e96c9d9be6fe6b15c79416e1d1903dcfef4" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/vimeo/psalm/zipball/b113f3ed0259fd6e212d87c3df80eec95a6abf19", - "reference": "b113f3ed0259fd6e212d87c3df80eec95a6abf19", + "url": "https://api.github.com/repos/vimeo/psalm/zipball/3f284e96c9d9be6fe6b15c79416e1d1903dcfef4", + "reference": "3f284e96c9d9be6fe6b15c79416e1d1903dcfef4", "shasum": "" }, "require": { @@ -5479,7 +5479,7 @@ "issues": "https://github.com/vimeo/psalm/issues", "source": "https://github.com/vimeo/psalm" }, - "time": "2023-12-16T09:37:35+00:00" + "time": "2024-01-18T12:15:06+00:00" }, { "name": "webimpress/coding-standard", diff --git a/psalm-baseline.xml b/psalm-baseline.xml index 12f91ef14..06fbd28f7 100644 --- a/psalm-baseline.xml +++ b/psalm-baseline.xml @@ -12,8 +12,6 @@ $closingBracket $closingBracket $closingBracket - $closingBracket - $closingBracket $val @@ -36,11 +34,6 @@ plugin - - - setResourceMap - - Cycle @@ -130,43 +123,6 @@ $value[$k] - - - pluginFlashMessenger]]> - - - $item - - - $escapeHtmlHelper - $pluginFlashMessenger - - - $item - $item - - - $classes - $classes - $messagesToPrint - - - $classes - $classes - $messagesToPrint[] - $messagesToPrint[] - escapeHtmlHelper]]> - - - (bool) $autoEscape - (string) $messageCloseString - (string) $messageOpenFormat - (string) $messageSeparatorString - - - escapeHtmlHelper]]> - - $flag === null @@ -191,9 +147,6 @@ options['rating']]]> options['secure']]]> - - ]]> - (bool) $flag (int) $imgSize @@ -417,26 +370,6 @@ HelperInterface - - - $htmlObject - - - $htmlObject($data, self::TYPE, $attribs, $params, $content) - - - string - - - $htmlObject($data, self::TYPE, $attribs, $params, $content) - - - plugin - - - plugin - - $options @@ -468,26 +401,6 @@ plugin - - - $htmlObject - - - $htmlObject($data, self::TYPE, $attribs, $params, $content) - - - string - - - $htmlObject($data, self::TYPE, $attribs, $params, $content) - - - plugin - - - plugin - - $value @@ -505,23 +418,6 @@ (bool) $useNamespaces - - - getAuthenticationService - setAuthenticationService - - - - - $response - - - null - - - response instanceof Response]]> - - plugin @@ -1114,7 +1010,6 @@ (string) $key (string) $key (string) $key - (string) $name containerClass($value)]]> @@ -1201,9 +1096,6 @@ - - null === static::$instance - containerClass($value)]]> @@ -1219,10 +1111,9 @@ AbstractContainer - - getRegistry - unsetRegistry - + + $instance + (string) $key (string) $key @@ -1230,9 +1121,6 @@ (string) $key (string) $key - - new static() - @@ -1306,11 +1194,6 @@ - - - $cName - - @@ -1323,50 +1206,7 @@ $config - - - FlashMessenger - FlashMessenger - new FlashMessenger() - - - FlashMessengerFactory - - - - - - $flashMessenger - - - - - - - - - - $config - $configHelper - $controllerPluginManager - $flashMessenger - - - get - - - $container - - - $requestedName - - - - $this - $this - $this - (bool) $enabled @@ -1456,22 +1296,6 @@ clearVariables - - - int - - - options['errorLevel']]]> - - - $captureTo - - - getErrorLevel - getResult - setResult - - type]]> @@ -1542,30 +1366,6 @@ is_object($variables) - - - $values - - - $value - - - getFilterChain()->filter($values['result'])]]> - - - $model - - - $values - - - __construct - setFilterChain - - - $config - - (array) $nameOrModel @@ -1590,9 +1390,6 @@ - - void - $jsonpCallback @@ -1735,19 +1532,11 @@ static::FAILURE_NOT_FOUND static::FAILURE_NO_PATHS - - setUseStreamWrapper - lastLookupFailure]]> lastLookupFailure]]> lastLookupFailure]]> lastLookupFailure]]> - useStreamWrapper]]> - useStreamWrapper]]> - useViewStream]]> - useViewStream]]> - useViewStream]]> is_string($path) @@ -1760,13 +1549,11 @@ - TemplatePathStack - (bool) $flag (bool) $flag (string) $defaultSuffix @@ -1825,48 +1612,6 @@ plugin - - - $data - $stat - - - $mode - $offset - $opened_path - $options - $whence - - - pos]]> - pos]]> - pos]]> - - - $offset - $offset - $offset - - - stream_eof - stream_open - stream_read - stream_seek - stream_stat - stream_tell - url_stat - - - $mode - $opened_path - $options - - - break; - break; - break; - - $value @@ -2002,75 +1747,6 @@ $test - - - $plugin - $plugin - mvcPluginClass]]> - - - FlashMessenger - [ - 'config' => $config, - ], - 'factories' => [ - 'ControllerPluginManager' => fn(ContainerInterface $services) => new PluginManager($services, [ - 'invokables' => [ - 'flashmessenger' => $this->mvcPluginClass, - ], - ]), - 'ViewHelperManager' => static fn(ContainerInterface $services) - => new HelperPluginManager($services), - ], - ])]]> - new FlashMessenger() - new FlashMessenger() - new FlashMessenger() - new FlashMessenger() - new FlashMessenger() - new FlashMessenger() - - - $displayInfo - $displayInfo - $displayInfo - $displayInfo - $helper - $helper - $helper - $helper - $helperPluginManager - $helperPluginManager - $helperPluginManager - $helperPluginManager - - - get - get - get - get - render - render - renderCurrent - renderCurrent - - - hasCurrentErrorMessages - hasCurrentInfoMessages - hasCurrentMessages - hasCurrentSuccessMessages - hasErrorMessages - hasInfoMessages - hasMessages - hasSuccessMessages - hasWarningMessages - render - render - renderCurrent - renderCurrent - - $value @@ -2168,11 +1844,6 @@ offsetSetName - - - HtmlFlash - - $key From d594cc3b227bfcfd0f85094e382afcf2245a4ce3 Mon Sep 17 00:00:00 2001 From: George Steel Date: Fri, 14 Jan 2022 11:49:33 +0000 Subject: [PATCH 44/58] Initial work on a migration guide for 3 Signed-off-by: George Steel --- docs/book/migrating.md | 36 ++++++++++++++++++++++++++++++++++++ mkdocs.yml | 2 ++ 2 files changed, 38 insertions(+) create mode 100644 docs/book/migrating.md diff --git a/docs/book/migrating.md b/docs/book/migrating.md new file mode 100644 index 000000000..1889d9e13 --- /dev/null +++ b/docs/book/migrating.md @@ -0,0 +1,36 @@ +# Migration Guide + +Version 3 is the first major release of `laminas-view` and includes a number of backwards incompatible changes. + +## Helper Removals + +### Flash Messenger + +The flash messenger view helper is no longer present in version 3 and has been migrated to a separate package: [laminas-mvc-plugin-flashmessenger](https://github.com/laminas/laminas-mvc-plugin-flashmessenger). In order to continue to use the flash messenger in your projects, you will need to explicitly require it in your composer dependencies. + +### Obsolete View Helpers: Flash and Quicktime + +The deprecated helpers `htmlFlash` and `htmlQuicktime` have been removed. If your project requires these helpers, you can make use of the [HtmlObject](helpers/html-object.md) view helper to achieve the same output. + +```php +echo $this->htmlObject( + 'path/to/flash.swf', + 'application/x-shockwave-flash', + [ + 'width' => 640, + 'height' => 480, + 'id' => 'long-live-flash' + ], + [ + 'movie' => 'path/to/flash.swf', + 'quality' => 'high' + ], + 'Fallback Text Content' +); +``` + +## Backwards Incompatible Changes to Helpers + +### Json View Helper + +In previous versions of laminas-view the [Json View Helper](helpers/json.md) made use of the [laminas-json](https://github.com/laminas/laminas-json) library which enabled encoding of [JSON Expressions](https://github.com/laminas/laminas-json/blob/3.4.x/docs/book/advanced.md#json-expressions). Support for this library and the expression finder feature has been removed. diff --git a/mkdocs.yml b/mkdocs.yml index c8d4e4643..24315a0bd 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -15,6 +15,7 @@ nav: - Cycle: v2/helpers/cycle.md - Doctype: v2/helpers/doctype.md - Escape: v2/helpers/escape.md + - FlashMessenger: v2/helpers/flash-messenger.md - Gravatar: v2/helpers/gravatar.md - HeadLink: v2/helpers/head-link.md - HeadMeta: v2/helpers/head-meta.md @@ -41,6 +42,7 @@ nav: - "Preparing for Version 3": v2/migration/preparing-for-v3.md - v3: - "Quick Start": v3/quick-start.md + - "Migrating from v2 to v3": migrating.md - "Rendering Views": - "The PhpRenderer": v3/php-renderer.md - "View Scripts": v3/view-scripts.md From ee947818281998d43c03cc552bfb03b75313b4f7 Mon Sep 17 00:00:00 2001 From: George Steel Date: Fri, 14 Jan 2022 13:05:29 +0000 Subject: [PATCH 45/58] Explicit title for applicable versions MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Frank Brückner Signed-off-by: George Steel --- docs/book/migrating.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/book/migrating.md b/docs/book/migrating.md index 1889d9e13..578671dda 100644 --- a/docs/book/migrating.md +++ b/docs/book/migrating.md @@ -1,4 +1,4 @@ -# Migration Guide +# Migration from Version 2 to 3 Version 3 is the first major release of `laminas-view` and includes a number of backwards incompatible changes. From 054b7ffda76c6536b79b5ad5eccd769870e6e4be Mon Sep 17 00:00:00 2001 From: George Steel Date: Fri, 14 Jan 2022 13:09:43 +0000 Subject: [PATCH 46/58] Relocate migration guide and move to the end of the navigation Signed-off-by: George Steel --- docs/book/{migrating.md => v3/migration/v2-to-v3.md} | 0 mkdocs.yml | 3 ++- 2 files changed, 2 insertions(+), 1 deletion(-) rename docs/book/{migrating.md => v3/migration/v2-to-v3.md} (100%) diff --git a/docs/book/migrating.md b/docs/book/v3/migration/v2-to-v3.md similarity index 100% rename from docs/book/migrating.md rename to docs/book/v3/migration/v2-to-v3.md diff --git a/mkdocs.yml b/mkdocs.yml index 24315a0bd..d0f255355 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -42,7 +42,6 @@ nav: - "Preparing for Version 3": v2/migration/preparing-for-v3.md - v3: - "Quick Start": v3/quick-start.md - - "Migrating from v2 to v3": migrating.md - "Rendering Views": - "The PhpRenderer": v3/php-renderer.md - "View Scripts": v3/view-scripts.md @@ -76,6 +75,8 @@ nav: - 'Stand-Alone': v3/application-integration/stand-alone.md - Cookbook: - "Setting module-specific Layouts": v3/cookbook/setting-module-specific-layouts.md + - Migration: + - "Migration from Version 2 to 3": v3/migration/v2-to-v3.md site_name: laminas-view site_description: 'Flexible view layer supporting and providing multiple view layers, helpers, and more.' repo_url: 'https://github.com/laminas/laminas-view' From 62132e33d688b9a56df715b5f4fb6ca20fa767b6 Mon Sep 17 00:00:00 2001 From: George Steel Date: Fri, 14 Jan 2022 13:18:55 +0000 Subject: [PATCH 47/58] Reformat content and add outline headings Signed-off-by: George Steel --- docs/book/v3/migration/v2-to-v3.md | 35 ++++++++++++++++++++---------- 1 file changed, 24 insertions(+), 11 deletions(-) diff --git a/docs/book/v3/migration/v2-to-v3.md b/docs/book/v3/migration/v2-to-v3.md index 578671dda..6cb717054 100644 --- a/docs/book/v3/migration/v2-to-v3.md +++ b/docs/book/v3/migration/v2-to-v3.md @@ -2,15 +2,34 @@ Version 3 is the first major release of `laminas-view` and includes a number of backwards incompatible changes. -## Helper Removals +## New Features -### Flash Messenger +## New Dependencies -The flash messenger view helper is no longer present in version 3 and has been migrated to a separate package: [laminas-mvc-plugin-flashmessenger](https://github.com/laminas/laminas-mvc-plugin-flashmessenger). In order to continue to use the flash messenger in your projects, you will need to explicitly require it in your composer dependencies. +## Signature Changes and Behaviour Changes -### Obsolete View Helpers: Flash and Quicktime +## Removed Features -The deprecated helpers `htmlFlash` and `htmlQuicktime` have been removed. If your project requires these helpers, you can make use of the [HtmlObject](helpers/html-object.md) view helper to achieve the same output. +### Helpers + +#### Json View Helper + +In previous versions of laminas-view the [Json View Helper](helpers/json.md) made use of the [laminas-json](https://docs.laminas.dev/laminas-json/) library which enabled encoding of [JSON Expressions](https://docs.laminas.dev/laminas-json/advanced/#json-expressions). +Support for this library and the expression finder feature has been removed. + +## Removed Class and Traits + +### Removed Helpers + +#### Flash Messenger + +The flash messenger view helper is no longer present in version 3 and has been migrated to a separate package: [laminas-mvc-plugin-flashmessenger](https://docs.laminas.dev/laminas-mvc-plugin-flashmessenger/). +In order to continue to use the flash messenger in your projects, you will need to explicitly require it in your composer dependencies. + +#### Flash and Quicktime + +The deprecated helpers `htmlFlash` and `htmlQuicktime` have been removed. +If your project requires these helpers, you can make use of the [HtmlObject](helpers/html-object.md) view helper to achieve the same output. ```php echo $this->htmlObject( @@ -28,9 +47,3 @@ echo $this->htmlObject( 'Fallback Text Content' ); ``` - -## Backwards Incompatible Changes to Helpers - -### Json View Helper - -In previous versions of laminas-view the [Json View Helper](helpers/json.md) made use of the [laminas-json](https://github.com/laminas/laminas-json) library which enabled encoding of [JSON Expressions](https://github.com/laminas/laminas-json/blob/3.4.x/docs/book/advanced.md#json-expressions). Support for this library and the expression finder feature has been removed. From 9ede37f7b2a7237b62bc1ec25deb569767c6a848 Mon Sep 17 00:00:00 2001 From: George Steel Date: Tue, 1 Feb 2022 15:33:37 +0000 Subject: [PATCH 48/58] Document removal of stream wrappers Signed-off-by: George Steel --- docs/book/v3/migration/v2-to-v3.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/docs/book/v3/migration/v2-to-v3.md b/docs/book/v3/migration/v2-to-v3.md index 6cb717054..970c8eb73 100644 --- a/docs/book/v3/migration/v2-to-v3.md +++ b/docs/book/v3/migration/v2-to-v3.md @@ -10,6 +10,12 @@ Version 3 is the first major release of `laminas-view` and includes a number of ## Removed Features +### Stream Wrapper Functionality + +In previous versions of laminas-view, it was possible to enable stream wrapper functionality in order to work around an inability to enable PHP's `short_open_tag` ini setting. +This functionality has been removed in version 3. +If you had not explicitly enabled this feature, this change will not affect your code. + ### Helpers #### Json View Helper From 6e92a88f8936103af4db1c6c62d1539fb32ed560 Mon Sep 17 00:00:00 2001 From: George Steel Date: Mon, 14 Feb 2022 10:12:39 +0000 Subject: [PATCH 49/58] Adds escape helper method removals Signed-off-by: George Steel --- docs/book/v3/migration/v2-to-v3.md | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/docs/book/v3/migration/v2-to-v3.md b/docs/book/v3/migration/v2-to-v3.md index 970c8eb73..ef84af161 100644 --- a/docs/book/v3/migration/v2-to-v3.md +++ b/docs/book/v3/migration/v2-to-v3.md @@ -18,6 +18,12 @@ If you had not explicitly enabled this feature, this change will not affect your ### Helpers +#### Escape Helpers: `escapeCss`, `escapeHtml`, `escapeHtmlAttr`, `escapeJs`, and `escapeUrl` + +The methods `setEncoding()`, `getEncoding()`, `setView()`, `getView()`, `setEscaper()`, and `getEscaper()` have been removed from the escape helpers. These helpers now have constructors that expect an [Escaper](https://docs.laminas.dev/laminas-escaper/) instance that has been configured with the encoding you expect to output in your view. + +The encoding defaults to UTF-8 as it has always done but can be overridden in configuration by setting `view_manager.encoding` to your preferred value. + #### Json View Helper In previous versions of laminas-view the [Json View Helper](helpers/json.md) made use of the [laminas-json](https://docs.laminas.dev/laminas-json/) library which enabled encoding of [JSON Expressions](https://docs.laminas.dev/laminas-json/advanced/#json-expressions). From e07020907fb5d995979880c8787a8d9f63a3cbc8 Mon Sep 17 00:00:00 2001 From: George Steel Date: Thu, 24 Mar 2022 14:54:51 +0000 Subject: [PATCH 50/58] Adds information about the gravatar helper replacement Signed-off-by: George Steel --- docs/book/v3/migration/v2-to-v3.md | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/docs/book/v3/migration/v2-to-v3.md b/docs/book/v3/migration/v2-to-v3.md index ef84af161..01d3e40c2 100644 --- a/docs/book/v3/migration/v2-to-v3.md +++ b/docs/book/v3/migration/v2-to-v3.md @@ -59,3 +59,17 @@ echo $this->htmlObject( 'Fallback Text Content' ); ``` + +#### Gravatar + +The deprecated Gravatar view helper has been removed and replaced with a simplified version that doesn't store any state. The replacement helper is called [GravatarImage](helpers/gravatar-image.md) and has the following signature when accessed via view scripts: + +```php +function gravatarImage( + string $email, + int $imageSize = 80, + array $imageAttributes = [], + string $defaultImage = 'mm', + string $rating = 'g' +); +``` From eab94756ce91b1e0509c0503b66d0430f7aec769 Mon Sep 17 00:00:00 2001 From: George Steel Date: Thu, 24 Mar 2022 15:03:15 +0000 Subject: [PATCH 51/58] Document removal of laminas console integration Signed-off-by: George Steel --- docs/book/v3/migration/v2-to-v3.md | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/docs/book/v3/migration/v2-to-v3.md b/docs/book/v3/migration/v2-to-v3.md index 01d3e40c2..e3eb2a6c7 100644 --- a/docs/book/v3/migration/v2-to-v3.md +++ b/docs/book/v3/migration/v2-to-v3.md @@ -16,6 +16,10 @@ In previous versions of laminas-view, it was possible to enable stream wrapper f This functionality has been removed in version 3. If you had not explicitly enabled this feature, this change will not affect your code. +### Laminas Console Integration + +`Laminas\View\RendererConsoleRenderer` and `Laminas\View\Model\ConsoleModel` have been removed effectively removing all support for the deprecated `laminas-console` component. + ### Helpers #### Escape Helpers: `escapeCss`, `escapeHtml`, `escapeHtmlAttr`, `escapeJs`, and `escapeUrl` From c6e9ab0f73aaa9ec863ce684c197e895fb8d329b Mon Sep 17 00:00:00 2001 From: George Steel Date: Thu, 24 Mar 2022 15:21:17 +0000 Subject: [PATCH 52/58] Document changes to the asset helper and reformat with one sentence per line Signed-off-by: George Steel --- docs/book/v3/migration/v2-to-v3.md | 15 +++++++++++++-- 1 file changed, 13 insertions(+), 2 deletions(-) diff --git a/docs/book/v3/migration/v2-to-v3.md b/docs/book/v3/migration/v2-to-v3.md index e3eb2a6c7..66a85a264 100644 --- a/docs/book/v3/migration/v2-to-v3.md +++ b/docs/book/v3/migration/v2-to-v3.md @@ -8,6 +8,15 @@ Version 3 is the first major release of `laminas-view` and includes a number of ## Signature Changes and Behaviour Changes +### Helpers + +#### Asset Helper + +Previous versions of the asset helper permitted run-time modification and retrieval of the resource map with `Laminas\View\Helper\Asset::setResourceMap()` and `Laminas\View\Helper\Asset::getResourceMap()`. +Both of these methods have been removed. +Now, the only way to configure the resource map is via constructor injection. +The method of configuring the resource map remains unchanged. + ## Removed Features ### Stream Wrapper Functionality @@ -24,7 +33,8 @@ If you had not explicitly enabled this feature, this change will not affect your #### Escape Helpers: `escapeCss`, `escapeHtml`, `escapeHtmlAttr`, `escapeJs`, and `escapeUrl` -The methods `setEncoding()`, `getEncoding()`, `setView()`, `getView()`, `setEscaper()`, and `getEscaper()` have been removed from the escape helpers. These helpers now have constructors that expect an [Escaper](https://docs.laminas.dev/laminas-escaper/) instance that has been configured with the encoding you expect to output in your view. +The methods `setEncoding()`, `getEncoding()`, `setView()`, `getView()`, `setEscaper()`, and `getEscaper()` have been removed from the escape helpers. +These helpers now have constructors that expect an [Escaper](https://docs.laminas.dev/laminas-escaper/) instance that has been configured with the encoding you expect to output in your view. The encoding defaults to UTF-8 as it has always done but can be overridden in configuration by setting `view_manager.encoding` to your preferred value. @@ -66,7 +76,8 @@ echo $this->htmlObject( #### Gravatar -The deprecated Gravatar view helper has been removed and replaced with a simplified version that doesn't store any state. The replacement helper is called [GravatarImage](helpers/gravatar-image.md) and has the following signature when accessed via view scripts: +The deprecated Gravatar view helper has been removed and replaced with a simplified version that doesn't store any state. +The replacement helper is called [GravatarImage](helpers/gravatar-image.md) and has the following signature when accessed via view scripts: ```php function gravatarImage( From f1066f6f77a4d774420815883c2931fff633c49f Mon Sep 17 00:00:00 2001 From: George Steel Date: Thu, 24 Mar 2022 15:38:42 +0000 Subject: [PATCH 53/58] Document changes to the identity helper Signed-off-by: George Steel --- docs/book/v3/migration/v2-to-v3.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/docs/book/v3/migration/v2-to-v3.md b/docs/book/v3/migration/v2-to-v3.md index 66a85a264..349860cd3 100644 --- a/docs/book/v3/migration/v2-to-v3.md +++ b/docs/book/v3/migration/v2-to-v3.md @@ -17,6 +17,11 @@ Both of these methods have been removed. Now, the only way to configure the resource map is via constructor injection. The method of configuring the resource map remains unchanged. +#### Identity Helper + +The deprecated runtime retrieval and modification of the underlying authentication service has been removed and the service must be injected into the helper constructor. +Specifically, the methods `Laminas\View\Helper\Identity::setAuthenticationService()` and `Laminas\View\Helper\Identity::getAuthenticationService()` have been removed. + ## Removed Features ### Stream Wrapper Functionality From 886d5808d4412043030b29c9d30f07ab3ab95488 Mon Sep 17 00:00:00 2001 From: George Steel Date: Thu, 24 Mar 2022 15:42:19 +0000 Subject: [PATCH 54/58] Add general note about removal of Zend aliases and service names Signed-off-by: George Steel --- docs/book/v3/migration/v2-to-v3.md | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/docs/book/v3/migration/v2-to-v3.md b/docs/book/v3/migration/v2-to-v3.md index 349860cd3..25b17c54f 100644 --- a/docs/book/v3/migration/v2-to-v3.md +++ b/docs/book/v3/migration/v2-to-v3.md @@ -8,6 +8,11 @@ Version 3 is the first major release of `laminas-view` and includes a number of ## Signature Changes and Behaviour Changes +### Legacy Zend-Related Service and Helper Names + +All helper aliases that referred to the `Zend` equivalent of a helper or service have been removed. +Similarly, factories that previously searched for services in the container such as a Translator or Authentication Service for example, no longer check for the presence of the Zend equivalent. + ### Helpers #### Asset Helper From 4cd899627776b2098b130e2c1ee58de01bdbda97 Mon Sep 17 00:00:00 2001 From: George Steel Date: Thu, 25 Jan 2024 13:15:15 +0000 Subject: [PATCH 55/58] Re-work the JSON view helper resolving deprecations and updating documentation Signed-off-by: George Steel --- docs/book/v2/migration/preparing-for-v3.md | 2 +- docs/book/v3/helpers/json.md | 19 +++----- docs/book/v3/migration/v2-to-v3.md | 7 +++ src/Helper/Json.php | 53 ++++------------------ src/Renderer/PhpRenderer.php | 2 +- test/Helper/JsonTest.php | 33 +++++--------- 6 files changed, 36 insertions(+), 80 deletions(-) diff --git a/docs/book/v2/migration/preparing-for-v3.md b/docs/book/v2/migration/preparing-for-v3.md index 6787e769c..284ac670f 100644 --- a/docs/book/v2/migration/preparing-for-v3.md +++ b/docs/book/v2/migration/preparing-for-v3.md @@ -30,7 +30,7 @@ try { } ``` -## Deprecations +## Deprecations ### Undocumented Behaviour diff --git a/docs/book/v3/helpers/json.md b/docs/book/v3/helpers/json.md index 655a9f788..913e07b0e 100644 --- a/docs/book/v3/helpers/json.md +++ b/docs/book/v3/helpers/json.md @@ -1,21 +1,16 @@ # Json -When creating views that return JSON, it's important to also set the appropriate -response header. The JSON view helper does exactly that. In addition, by -default, it disables layouts (if currently enabled), as layouts generally aren't -used with JSON responses. +This view helper simply encodes its argument to JSON. -The JSON helper sets the following header: +## Basic Usage -```http -Content-Type: application/json +```php +json(['example' => 'payload']) ?> ``` -Most XmlHttpRequest libraries look for this header when parsing responses to -determine how to handle the content. - -## Basic Usage +The helper accepts a second argument `$jsonOptions`, an associative array with one possible key: `prettyPrint`. +Providing the value `['prettyPrint' => true]` will pretty-print the encoded data. ```php -json($this->data) ?> +json($data, ['prettyPrint' => true]) ?> ``` diff --git a/docs/book/v3/migration/v2-to-v3.md b/docs/book/v3/migration/v2-to-v3.md index 25b17c54f..646f2239d 100644 --- a/docs/book/v3/migration/v2-to-v3.md +++ b/docs/book/v3/migration/v2-to-v3.md @@ -27,6 +27,10 @@ The method of configuring the resource map remains unchanged. The deprecated runtime retrieval and modification of the underlying authentication service has been removed and the service must be injected into the helper constructor. Specifically, the methods `Laminas\View\Helper\Identity::setAuthenticationService()` and `Laminas\View\Helper\Identity::getAuthenticationService()` have been removed. +#### Json Helper + +The JSON view helper is now final and has no inheritance hierarchy. + ## Removed Features ### Stream Wrapper Functionality @@ -53,6 +57,9 @@ The encoding defaults to UTF-8 as it has always done but can be overridden in co In previous versions of laminas-view the [Json View Helper](helpers/json.md) made use of the [laminas-json](https://docs.laminas.dev/laminas-json/) library which enabled encoding of [JSON Expressions](https://docs.laminas.dev/laminas-json/advanced/#json-expressions). Support for this library and the expression finder feature has been removed. +In an MVC context, it was possible, in version 2, to provide a response object to the helper. +Invoking the helper would set the appropriate response headers for a JSON payload. This is no longer possible and the method `setResponse` has been removed. + ## Removed Class and Traits ### Removed Helpers diff --git a/src/Helper/Json.php b/src/Helper/Json.php index 542119922..80ae0e641 100644 --- a/src/Helper/Json.php +++ b/src/Helper/Json.php @@ -4,8 +4,6 @@ namespace Laminas\View\Helper; -use Laminas\Http\Response; - use function json_encode; use const JSON_PRETTY_PRINT; @@ -13,38 +11,19 @@ /** * Helper for simplifying JSON responses - * - * @psalm-suppress DeprecatedProperty - * @final */ -class Json extends AbstractHelper +final class Json { - use DeprecatedAbstractHelperHierarchyTrait; - - /** - * @deprecated since >= 2.20.0 - * - * @var Response|null - */ - protected $response; - /** - * Encode data as JSON and set response header + * Encode data as JSON * - * @param mixed $data - * @param array{prettyPrint?: bool} $jsonOptions Options to pass to JsonFormatter::encode() - * @return string + * @param array{prettyPrint?: bool} $jsonOptions + * @return non-empty-string */ - public function __invoke($data, array $jsonOptions = []) + public function __invoke(mixed $data, array $jsonOptions = []): string { - $data = json_encode($data, $this->optionsToFlags($jsonOptions)); - - if ($this->response instanceof Response) { - $headers = $this->response->getHeaders(); - $headers->addHeaderLine('Content-Type', 'application/json'); - } - - return $data; + /** @psalm-var non-empty-string */ + return json_encode($data, $this->optionsToFlags($jsonOptions)); } /** @param array{prettyPrint?: bool} $options */ @@ -52,24 +31,8 @@ private function optionsToFlags(array $options = []): int { $prettyPrint = $options['prettyPrint'] ?? false; $flags = JSON_THROW_ON_ERROR; - $flags |= $prettyPrint ? 0 : JSON_PRETTY_PRINT; + $flags |= $prettyPrint === false ? 0 : JSON_PRETTY_PRINT; return $flags; } - - /** - * Set the response object - * - * @deprecated since >= 2.20.0. If you need to set response headers, use the methods available in - * the framework. For example in Laminas MVC this can be achieved in the controller or in - * Mezzio, you can change response headers in Middleware. This method will be removed in 3.0 - * without replacement functionality. - * - * @return Json - */ - public function setResponse(Response $response) - { - $this->response = $response; - return $this; - } } diff --git a/src/Renderer/PhpRenderer.php b/src/Renderer/PhpRenderer.php index 271cf33da..ea1d37582 100644 --- a/src/Renderer/PhpRenderer.php +++ b/src/Renderer/PhpRenderer.php @@ -69,7 +69,7 @@ * @method string htmlPage($data, array $attribs = array(), array $params = array(), $content = null) * @method mixed|null identity() * @method \Laminas\View\Helper\InlineScript inlineScript($mode = \Laminas\View\Helper\HeadScript::FILE, $spec = null, $placement = 'APPEND', array $attrs = array(), $type = 'text/javascript') - * @method string|void json($data, array $jsonOptions = array()) + * @method string json(mixed $data, array $jsonOptions = []) * @method \Laminas\View\Helper\Layout layout($template = null) * @method \Laminas\View\Helper\Navigation navigation($container = null) * @method string paginationControl(\Laminas\Paginator\Paginator $paginator = null, $scrollingStyle = null, $partial = null, $params = null) diff --git a/test/Helper/JsonTest.php b/test/Helper/JsonTest.php index b829abf73..5550b51a2 100644 --- a/test/Helper/JsonTest.php +++ b/test/Helper/JsonTest.php @@ -4,18 +4,16 @@ namespace LaminasTest\View\Helper; -use Laminas\Http\Header\HeaderInterface; -use Laminas\Http\Response; use Laminas\View\Helper\Json as JsonHelper; use PHPUnit\Framework\TestCase; use function json_encode; +use const JSON_PRETTY_PRINT; use const JSON_THROW_ON_ERROR; class JsonTest extends TestCase { - private Response $response; private JsonHelper $helper; /** @@ -24,33 +22,26 @@ class JsonTest extends TestCase */ protected function setUp(): void { - $this->response = new Response(); - $this->helper = new JsonHelper(); - $this->helper->setResponse($this->response); + $this->helper = new JsonHelper(); } - private function verifyJsonHeader(): void - { - $headers = $this->response->getHeaders(); - $this->assertTrue($headers->has('Content-Type')); - $header = $headers->get('Content-Type'); - self::assertInstanceOf(HeaderInterface::class, $header); - $this->assertEquals('application/json', $header->getFieldValue()); - } - - public function testJsonHelperSetsResponseHeader(): void + public function testJsonHelperReturnsJsonEncodedString(): void { - $this->helper->__invoke('foobar'); - $this->verifyJsonHeader(); + $input = [ + 'dory' => 'blue', + 'nemo' => 'orange', + ]; + $expect = json_encode($input, JSON_THROW_ON_ERROR); + self::assertJsonStringEqualsJsonString($expect, ($this->helper)->__invoke($input)); } - public function testJsonHelperReturnsJsonEncodedString(): void + public function testTheHelperWillPrettyPrintWhenRequired(): void { $input = [ 'dory' => 'blue', 'nemo' => 'orange', ]; - $expect = json_encode($input, JSON_THROW_ON_ERROR); - self::assertJsonStringEqualsJsonString($expect, ($this->helper)($input)); + $expect = json_encode($input, JSON_THROW_ON_ERROR | JSON_PRETTY_PRINT); + self::assertSame($expect, ($this->helper)->__invoke($input, ['prettyPrint' => true])); } } From 930c31c26c57112d76ec97e42135a28f799e5304 Mon Sep 17 00:00:00 2001 From: George Steel Date: Fri, 26 Jan 2024 09:59:05 +0000 Subject: [PATCH 56/58] Remove the Json view helper entirely Signed-off-by: George Steel --- docs/book/v3/helpers/json.md | 16 ---------- docs/book/v3/migration/v2-to-v3.md | 17 ++++------- mkdocs.yml | 2 -- src/Helper/Json.php | 38 ------------------------ src/HelperPluginManager.php | 4 --- src/Renderer/PhpRenderer.php | 1 - test/Helper/JsonTest.php | 47 ------------------------------ 7 files changed, 5 insertions(+), 120 deletions(-) delete mode 100644 docs/book/v3/helpers/json.md delete mode 100644 src/Helper/Json.php delete mode 100644 test/Helper/JsonTest.php diff --git a/docs/book/v3/helpers/json.md b/docs/book/v3/helpers/json.md deleted file mode 100644 index 913e07b0e..000000000 --- a/docs/book/v3/helpers/json.md +++ /dev/null @@ -1,16 +0,0 @@ -# Json - -This view helper simply encodes its argument to JSON. - -## Basic Usage - -```php -json(['example' => 'payload']) ?> -``` - -The helper accepts a second argument `$jsonOptions`, an associative array with one possible key: `prettyPrint`. -Providing the value `['prettyPrint' => true]` will pretty-print the encoded data. - -```php -json($data, ['prettyPrint' => true]) ?> -``` diff --git a/docs/book/v3/migration/v2-to-v3.md b/docs/book/v3/migration/v2-to-v3.md index 646f2239d..2ac042c51 100644 --- a/docs/book/v3/migration/v2-to-v3.md +++ b/docs/book/v3/migration/v2-to-v3.md @@ -27,10 +27,6 @@ The method of configuring the resource map remains unchanged. The deprecated runtime retrieval and modification of the underlying authentication service has been removed and the service must be injected into the helper constructor. Specifically, the methods `Laminas\View\Helper\Identity::setAuthenticationService()` and `Laminas\View\Helper\Identity::getAuthenticationService()` have been removed. -#### Json Helper - -The JSON view helper is now final and has no inheritance hierarchy. - ## Removed Features ### Stream Wrapper Functionality @@ -52,14 +48,6 @@ These helpers now have constructors that expect an [Escaper](https://docs.lamina The encoding defaults to UTF-8 as it has always done but can be overridden in configuration by setting `view_manager.encoding` to your preferred value. -#### Json View Helper - -In previous versions of laminas-view the [Json View Helper](helpers/json.md) made use of the [laminas-json](https://docs.laminas.dev/laminas-json/) library which enabled encoding of [JSON Expressions](https://docs.laminas.dev/laminas-json/advanced/#json-expressions). -Support for this library and the expression finder feature has been removed. - -In an MVC context, it was possible, in version 2, to provide a response object to the helper. -Invoking the helper would set the appropriate response headers for a JSON payload. This is no longer possible and the method `setResponse` has been removed. - ## Removed Class and Traits ### Removed Helpers @@ -105,3 +93,8 @@ function gravatarImage( string $rating = 'g' ); ``` + +#### Json + +The deprecated Json view helper has been removed. +To encode data to Json for output in a view, you can call [`json_encode`](https://www.php.net/json_encode) directly. diff --git a/mkdocs.yml b/mkdocs.yml index d0f255355..52687be90 100644 --- a/mkdocs.yml +++ b/mkdocs.yml @@ -65,7 +65,6 @@ nav: - HtmlTag: v3/helpers/html-tag.md - Identity: v3/helpers/identity.md - InlineScript: v3/helpers/inline-script.md - - Json: v3/helpers/json.md - Layout: v3/helpers/layout.md - Partial: v3/helpers/partial.md - Placeholder: v3/helpers/placeholder.md @@ -115,7 +114,6 @@ plugins: helpers/html-tag.md: v3/helpers/html-tag.md helpers/identity.md: v3/helpers/identity.md helpers/inline-script.md: v3/helpers/inline-script.md - helpers/json.md: v3/helpers/json.md helpers/layout.md: v3/helpers/layout.md helpers/partial.md: v3/helpers/partial.md helpers/placeholder.md: v3/helpers/placeholder.md diff --git a/src/Helper/Json.php b/src/Helper/Json.php deleted file mode 100644 index 80ae0e641..000000000 --- a/src/Helper/Json.php +++ /dev/null @@ -1,38 +0,0 @@ -optionsToFlags($jsonOptions)); - } - - /** @param array{prettyPrint?: bool} $options */ - private function optionsToFlags(array $options = []): int - { - $prettyPrint = $options['prettyPrint'] ?? false; - $flags = JSON_THROW_ON_ERROR; - $flags |= $prettyPrint === false ? 0 : JSON_PRETTY_PRINT; - - return $flags; - } -} diff --git a/src/HelperPluginManager.php b/src/HelperPluginManager.php index bbadf35a4..7a01f7f70 100644 --- a/src/HelperPluginManager.php +++ b/src/HelperPluginManager.php @@ -111,8 +111,6 @@ class HelperPluginManager extends AbstractPluginManager 'inlinescript' => Helper\InlineScript::class, 'inlineScript' => Helper\InlineScript::class, 'InlineScript' => Helper\InlineScript::class, - 'json' => Helper\Json::class, - 'Json' => Helper\Json::class, 'layout' => Helper\Layout::class, 'Layout' => Helper\Layout::class, 'paginationcontrol' => Helper\PaginationControl::class, @@ -181,7 +179,6 @@ class HelperPluginManager extends AbstractPluginManager Helper\HtmlObject::class => InvokableFactory::class, Helper\HtmlPage::class => InvokableFactory::class, Helper\InlineScript::class => InvokableFactory::class, - Helper\Json::class => InvokableFactory::class, Helper\Layout::class => InvokableFactory::class, Helper\PaginationControl::class => InvokableFactory::class, Helper\PartialLoop::class => InvokableFactory::class, @@ -217,7 +214,6 @@ class HelperPluginManager extends AbstractPluginManager 'laminasviewhelperhtmlobject' => InvokableFactory::class, 'laminasviewhelperhtmlpage' => InvokableFactory::class, 'laminasviewhelperinlinescript' => InvokableFactory::class, - 'laminasviewhelperjson' => InvokableFactory::class, 'laminasviewhelperlayout' => InvokableFactory::class, 'laminasviewhelperpaginationcontrol' => InvokableFactory::class, 'laminasviewhelperpartialloop' => InvokableFactory::class, diff --git a/src/Renderer/PhpRenderer.php b/src/Renderer/PhpRenderer.php index ea1d37582..050dc29bf 100644 --- a/src/Renderer/PhpRenderer.php +++ b/src/Renderer/PhpRenderer.php @@ -69,7 +69,6 @@ * @method string htmlPage($data, array $attribs = array(), array $params = array(), $content = null) * @method mixed|null identity() * @method \Laminas\View\Helper\InlineScript inlineScript($mode = \Laminas\View\Helper\HeadScript::FILE, $spec = null, $placement = 'APPEND', array $attrs = array(), $type = 'text/javascript') - * @method string json(mixed $data, array $jsonOptions = []) * @method \Laminas\View\Helper\Layout layout($template = null) * @method \Laminas\View\Helper\Navigation navigation($container = null) * @method string paginationControl(\Laminas\Paginator\Paginator $paginator = null, $scrollingStyle = null, $partial = null, $params = null) diff --git a/test/Helper/JsonTest.php b/test/Helper/JsonTest.php deleted file mode 100644 index 5550b51a2..000000000 --- a/test/Helper/JsonTest.php +++ /dev/null @@ -1,47 +0,0 @@ -helper = new JsonHelper(); - } - - public function testJsonHelperReturnsJsonEncodedString(): void - { - $input = [ - 'dory' => 'blue', - 'nemo' => 'orange', - ]; - $expect = json_encode($input, JSON_THROW_ON_ERROR); - self::assertJsonStringEqualsJsonString($expect, ($this->helper)->__invoke($input)); - } - - public function testTheHelperWillPrettyPrintWhenRequired(): void - { - $input = [ - 'dory' => 'blue', - 'nemo' => 'orange', - ]; - $expect = json_encode($input, JSON_THROW_ON_ERROR | JSON_PRETTY_PRINT); - self::assertSame($expect, ($this->helper)->__invoke($input, ['prettyPrint' => true])); - } -} From 590a0c50f169221b8c27a664406ace3360726a69 Mon Sep 17 00:00:00 2001 From: George Steel Date: Fri, 26 Jan 2024 10:12:33 +0000 Subject: [PATCH 57/58] Additional guidance on json_encode for v3 migration Signed-off-by: George Steel --- docs/book/v3/migration/v2-to-v3.md | 3 +++ 1 file changed, 3 insertions(+) diff --git a/docs/book/v3/migration/v2-to-v3.md b/docs/book/v3/migration/v2-to-v3.md index 2ac042c51..94fd41f6b 100644 --- a/docs/book/v3/migration/v2-to-v3.md +++ b/docs/book/v3/migration/v2-to-v3.md @@ -98,3 +98,6 @@ function gravatarImage( The deprecated Json view helper has been removed. To encode data to Json for output in a view, you can call [`json_encode`](https://www.php.net/json_encode) directly. + +If you were relying on behaviour that was previously available via `laminas-json`, for example, calling object methods `toArray` or `toJson` prior to encoding, you should make the relevant objects implement `JsonSerializable`. +You can find documentation on the `JsonSerializable` interface [on the PHP website](https://www.php.net/manual/en/class.jsonserializable.php). From d202ab9c76693b4b9d9174694241222f7a8f13c8 Mon Sep 17 00:00:00 2001 From: George Steel Date: Mon, 5 Feb 2024 12:48:18 +0000 Subject: [PATCH 58/58] Use language-less links to the PHP docs MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Co-authored-by: Frank Brückner Signed-off-by: George Steel --- docs/book/v3/migration/v2-to-v3.md | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/docs/book/v3/migration/v2-to-v3.md b/docs/book/v3/migration/v2-to-v3.md index 94fd41f6b..c6eae30ec 100644 --- a/docs/book/v3/migration/v2-to-v3.md +++ b/docs/book/v3/migration/v2-to-v3.md @@ -100,4 +100,4 @@ The deprecated Json view helper has been removed. To encode data to Json for output in a view, you can call [`json_encode`](https://www.php.net/json_encode) directly. If you were relying on behaviour that was previously available via `laminas-json`, for example, calling object methods `toArray` or `toJson` prior to encoding, you should make the relevant objects implement `JsonSerializable`. -You can find documentation on the `JsonSerializable` interface [on the PHP website](https://www.php.net/manual/en/class.jsonserializable.php). +You can find documentation on the `JsonSerializable` interface [on the PHP website](https://www.php.net/manual/class.jsonserializable.php).