From 77ee5d7ecd97d17a4ba4fcb19ad5adada5aeb664 Mon Sep 17 00:00:00 2001 From: Ahmet Bora Date: Thu, 13 Jun 2024 12:46:27 +0300 Subject: [PATCH] Update composer dependencies --- composer.json | 4 +- composer.lock | 40 ++++++++--------- vendor/bin/yaml-lint.bat | 5 +++ .../simpleimage/src/claviska/SimpleImage.php | 26 +++++++++-- vendor/composer/installed.json | 44 +++++++++---------- vendor/composer/installed.php | 18 ++++---- .../deprecation-contracts/composer.json | 2 +- vendor/symfony/yaml/Parser.php | 4 +- 8 files changed, 83 insertions(+), 60 deletions(-) create mode 100644 vendor/bin/yaml-lint.bat diff --git a/composer.json b/composer.json index e9aec94baf..1320655f4f 100644 --- a/composer.json +++ b/composer.json @@ -37,7 +37,7 @@ "ext-mbstring": "*", "ext-openssl": "*", "christian-riesen/base32": "1.6.0", - "claviska/simpleimage": "4.1.0", + "claviska/simpleimage": "4.2.0", "composer/semver": "3.4.0", "filp/whoops": "2.15.4", "getkirby/composer-installer": "^1.2.1", @@ -46,7 +46,7 @@ "phpmailer/phpmailer": "6.9.1", "symfony/polyfill-intl-idn": "1.29.0", "symfony/polyfill-mbstring": "1.29.0", - "symfony/yaml": "6.4.3" + "symfony/yaml": "6.4.8" }, "replace": { "symfony/polyfill-php72": "*" diff --git a/composer.lock b/composer.lock index 53327d72d4..f3c8063a21 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": "54b16f9c89e4539548e2a0e0bdf99d22", + "content-hash": "c551d482274b5418356af010c4845227", "packages": [ { "name": "christian-riesen/base32", @@ -67,16 +67,16 @@ }, { "name": "claviska/simpleimage", - "version": "4.1.0", + "version": "4.2.0", "source": { "type": "git", "url": "https://github.com/claviska/SimpleImage.git", - "reference": "1dcb9c785c44960890970d26e25c437a2a252bbf" + "reference": "dfbe53c01dae8467468ef2b817c09b786a7839d2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/claviska/SimpleImage/zipball/1dcb9c785c44960890970d26e25c437a2a252bbf", - "reference": "1dcb9c785c44960890970d26e25c437a2a252bbf", + "url": "https://api.github.com/repos/claviska/SimpleImage/zipball/dfbe53c01dae8467468ef2b817c09b786a7839d2", + "reference": "dfbe53c01dae8467468ef2b817c09b786a7839d2", "shasum": "" }, "require": { @@ -108,7 +108,7 @@ "description": "A PHP class that makes working with images as simple as possible.", "support": { "issues": "https://github.com/claviska/SimpleImage/issues", - "source": "https://github.com/claviska/SimpleImage/tree/4.1.0" + "source": "https://github.com/claviska/SimpleImage/tree/4.2.0" }, "funding": [ { @@ -116,7 +116,7 @@ "type": "github" } ], - "time": "2024-03-04T15:41:11+00:00" + "time": "2024-04-15T16:07:16+00:00" }, { "name": "composer/semver", @@ -627,16 +627,16 @@ }, { "name": "symfony/deprecation-contracts", - "version": "v3.4.0", + "version": "v3.5.0", "source": { "type": "git", "url": "https://github.com/symfony/deprecation-contracts.git", - "reference": "7c3aff79d10325257a001fcf92d991f24fc967cf" + "reference": "0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/7c3aff79d10325257a001fcf92d991f24fc967cf", - "reference": "7c3aff79d10325257a001fcf92d991f24fc967cf", + "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1", + "reference": "0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1", "shasum": "" }, "require": { @@ -645,7 +645,7 @@ "type": "library", "extra": { "branch-alias": { - "dev-main": "3.4-dev" + "dev-main": "3.5-dev" }, "thanks": { "name": "symfony/contracts", @@ -674,7 +674,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.4.0" + "source": "https://github.com/symfony/deprecation-contracts/tree/v3.5.0" }, "funding": [ { @@ -690,7 +690,7 @@ "type": "tidelift" } ], - "time": "2023-05-23T14:45:45+00:00" + "time": "2024-04-18T09:32:20+00:00" }, { "name": "symfony/polyfill-ctype", @@ -1018,16 +1018,16 @@ }, { "name": "symfony/yaml", - "version": "v6.4.3", + "version": "v6.4.8", "source": { "type": "git", "url": "https://github.com/symfony/yaml.git", - "reference": "d75715985f0f94f978e3a8fa42533e10db921b90" + "reference": "52903de178d542850f6f341ba92995d3d63e60c9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/yaml/zipball/d75715985f0f94f978e3a8fa42533e10db921b90", - "reference": "d75715985f0f94f978e3a8fa42533e10db921b90", + "url": "https://api.github.com/repos/symfony/yaml/zipball/52903de178d542850f6f341ba92995d3d63e60c9", + "reference": "52903de178d542850f6f341ba92995d3d63e60c9", "shasum": "" }, "require": { @@ -1070,7 +1070,7 @@ "description": "Loads and dumps YAML files", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/yaml/tree/v6.4.3" + "source": "https://github.com/symfony/yaml/tree/v6.4.8" }, "funding": [ { @@ -1086,7 +1086,7 @@ "type": "tidelift" } ], - "time": "2024-01-23T14:51:35+00:00" + "time": "2024-05-31T14:49:08+00:00" } ], "packages-dev": [], diff --git a/vendor/bin/yaml-lint.bat b/vendor/bin/yaml-lint.bat new file mode 100644 index 0000000000..fbce06e043 --- /dev/null +++ b/vendor/bin/yaml-lint.bat @@ -0,0 +1,5 @@ +@ECHO OFF +setlocal DISABLEDELAYEDEXPANSION +SET BIN_TARGET=%~dp0/yaml-lint +SET COMPOSER_RUNTIME_BIN_DIR=%~dp0 +php "%BIN_TARGET%" %* diff --git a/vendor/claviska/simpleimage/src/claviska/SimpleImage.php b/vendor/claviska/simpleimage/src/claviska/SimpleImage.php index 75a1826045..c9c0c7b0bf 100644 --- a/vendor/claviska/simpleimage/src/claviska/SimpleImage.php +++ b/vendor/claviska/simpleimage/src/claviska/SimpleImage.php @@ -116,15 +116,33 @@ public function __construct(string $image = '', array $flags = []) */ public function __destruct() { - if ($this->image instanceof GdImage) { - imagedestroy($this->image); - } + $this->reset(); } ////////////////////////////////////////////////////////////////////////////////////////////////// // Helper functions ////////////////////////////////////////////////////////////////////////////////////////////////// + /** + * Checks if the SimpleImage object has loaded an image. + */ + public function hasImage(): bool + { + return $this->image instanceof GdImage; + } + + /** + * Destroys the image resource. + */ + public function reset(): static + { + if ($this->hasImage()) { + imagedestroy($this->image); + } + + return $this; + } + /** * Set flag value. * @@ -313,7 +331,7 @@ public function fromString(string $string): SimpleImage|static * * @throws Exception Thrown when WEBP support is not enabled or unsupported format. */ - protected function generate(string $mimeType = null, array|int $options = []): array + public function generate(string $mimeType = null, array|int $options = 100): array { // Format defaults to the original mime type $mimeType = $mimeType ?: $this->mimeType; diff --git a/vendor/composer/installed.json b/vendor/composer/installed.json index d547dcc6a4..97a71fa5f6 100644 --- a/vendor/composer/installed.json +++ b/vendor/composer/installed.json @@ -64,17 +64,17 @@ }, { "name": "claviska/simpleimage", - "version": "4.1.0", - "version_normalized": "4.1.0.0", + "version": "4.2.0", + "version_normalized": "4.2.0.0", "source": { "type": "git", "url": "https://github.com/claviska/SimpleImage.git", - "reference": "1dcb9c785c44960890970d26e25c437a2a252bbf" + "reference": "dfbe53c01dae8467468ef2b817c09b786a7839d2" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/claviska/SimpleImage/zipball/1dcb9c785c44960890970d26e25c437a2a252bbf", - "reference": "1dcb9c785c44960890970d26e25c437a2a252bbf", + "url": "https://api.github.com/repos/claviska/SimpleImage/zipball/dfbe53c01dae8467468ef2b817c09b786a7839d2", + "reference": "dfbe53c01dae8467468ef2b817c09b786a7839d2", "shasum": "" }, "require": { @@ -86,7 +86,7 @@ "laravel/pint": "^1.5", "phpstan/phpstan": "^1.10" }, - "time": "2024-03-04T15:41:11+00:00", + "time": "2024-04-15T16:07:16+00:00", "type": "library", "installation-source": "dist", "autoload": { @@ -108,7 +108,7 @@ "description": "A PHP class that makes working with images as simple as possible.", "support": { "issues": "https://github.com/claviska/SimpleImage/issues", - "source": "https://github.com/claviska/SimpleImage/tree/4.1.0" + "source": "https://github.com/claviska/SimpleImage/tree/4.2.0" }, "funding": [ { @@ -651,27 +651,27 @@ }, { "name": "symfony/deprecation-contracts", - "version": "v3.4.0", - "version_normalized": "3.4.0.0", + "version": "v3.5.0", + "version_normalized": "3.5.0.0", "source": { "type": "git", "url": "https://github.com/symfony/deprecation-contracts.git", - "reference": "7c3aff79d10325257a001fcf92d991f24fc967cf" + "reference": "0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/7c3aff79d10325257a001fcf92d991f24fc967cf", - "reference": "7c3aff79d10325257a001fcf92d991f24fc967cf", + "url": "https://api.github.com/repos/symfony/deprecation-contracts/zipball/0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1", + "reference": "0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1", "shasum": "" }, "require": { "php": ">=8.1" }, - "time": "2023-05-23T14:45:45+00:00", + "time": "2024-04-18T09:32:20+00:00", "type": "library", "extra": { "branch-alias": { - "dev-main": "3.4-dev" + "dev-main": "3.5-dev" }, "thanks": { "name": "symfony/contracts", @@ -701,7 +701,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.4.0" + "source": "https://github.com/symfony/deprecation-contracts/tree/v3.5.0" }, "funding": [ { @@ -1057,17 +1057,17 @@ }, { "name": "symfony/yaml", - "version": "v6.4.3", - "version_normalized": "6.4.3.0", + "version": "v6.4.8", + "version_normalized": "6.4.8.0", "source": { "type": "git", "url": "https://github.com/symfony/yaml.git", - "reference": "d75715985f0f94f978e3a8fa42533e10db921b90" + "reference": "52903de178d542850f6f341ba92995d3d63e60c9" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/symfony/yaml/zipball/d75715985f0f94f978e3a8fa42533e10db921b90", - "reference": "d75715985f0f94f978e3a8fa42533e10db921b90", + "url": "https://api.github.com/repos/symfony/yaml/zipball/52903de178d542850f6f341ba92995d3d63e60c9", + "reference": "52903de178d542850f6f341ba92995d3d63e60c9", "shasum": "" }, "require": { @@ -1081,7 +1081,7 @@ "require-dev": { "symfony/console": "^5.4|^6.0|^7.0" }, - "time": "2024-01-23T14:51:35+00:00", + "time": "2024-05-31T14:49:08+00:00", "bin": [ "Resources/bin/yaml-lint" ], @@ -1112,7 +1112,7 @@ "description": "Loads and dumps YAML files", "homepage": "https://symfony.com", "support": { - "source": "https://github.com/symfony/yaml/tree/v6.4.3" + "source": "https://github.com/symfony/yaml/tree/v6.4.8" }, "funding": [ { diff --git a/vendor/composer/installed.php b/vendor/composer/installed.php index 3f2d30a95b..663aa180d0 100644 --- a/vendor/composer/installed.php +++ b/vendor/composer/installed.php @@ -20,9 +20,9 @@ 'dev_requirement' => false, ), 'claviska/simpleimage' => array( - 'pretty_version' => '4.1.0', - 'version' => '4.1.0.0', - 'reference' => '1dcb9c785c44960890970d26e25c437a2a252bbf', + 'pretty_version' => '4.2.0', + 'version' => '4.2.0.0', + 'reference' => 'dfbe53c01dae8467468ef2b817c09b786a7839d2', 'type' => 'library', 'install_path' => __DIR__ . '/../claviska/simpleimage', 'aliases' => array(), @@ -116,9 +116,9 @@ 'dev_requirement' => false, ), 'symfony/deprecation-contracts' => array( - 'pretty_version' => 'v3.4.0', - 'version' => '3.4.0.0', - 'reference' => '7c3aff79d10325257a001fcf92d991f24fc967cf', + 'pretty_version' => 'v3.5.0', + 'version' => '3.5.0.0', + 'reference' => '0e0d29ce1f20deffb4ab1b016a7257c4f1e789a1', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/deprecation-contracts', 'aliases' => array(), @@ -167,9 +167,9 @@ ), ), 'symfony/yaml' => array( - 'pretty_version' => 'v6.4.3', - 'version' => '6.4.3.0', - 'reference' => 'd75715985f0f94f978e3a8fa42533e10db921b90', + 'pretty_version' => 'v6.4.8', + 'version' => '6.4.8.0', + 'reference' => '52903de178d542850f6f341ba92995d3d63e60c9', 'type' => 'library', 'install_path' => __DIR__ . '/../symfony/yaml', 'aliases' => array(), diff --git a/vendor/symfony/deprecation-contracts/composer.json b/vendor/symfony/deprecation-contracts/composer.json index c6d02d8749..ceb6c07961 100644 --- a/vendor/symfony/deprecation-contracts/composer.json +++ b/vendor/symfony/deprecation-contracts/composer.json @@ -25,7 +25,7 @@ "minimum-stability": "dev", "extra": { "branch-alias": { - "dev-main": "3.4-dev" + "dev-main": "3.5-dev" }, "thanks": { "name": "symfony/contracts", diff --git a/vendor/symfony/yaml/Parser.php b/vendor/symfony/yaml/Parser.php index e4de9454b0..2a15bcae3d 100644 --- a/vendor/symfony/yaml/Parser.php +++ b/vendor/symfony/yaml/Parser.php @@ -638,12 +638,12 @@ private function getNextEmbedBlock(?int $indentation = null, bool $inSequence = } if ($this->isCurrentLineBlank()) { - $data[] = substr($this->currentLine, $newIndent); + $data[] = substr($this->currentLine, $newIndent ?? 0); continue; } if ($indent >= $newIndent) { - $data[] = substr($this->currentLine, $newIndent); + $data[] = substr($this->currentLine, $newIndent ?? 0); } elseif ($this->isCurrentLineComment()) { $data[] = $this->currentLine; } elseif (0 == $indent) {