From 74f95dc3f22379fb4cb1e8c8fdc60a8f53527a47 Mon Sep 17 00:00:00 2001 From: Baptiste Langlade Date: Sat, 15 Nov 2025 14:12:57 +0100 Subject: [PATCH 1/9] require php 8.4 --- .github/workflows/ci.yml | 10 ++++------ CHANGELOG.md | 6 ++++++ composer.json | 2 +- 3 files changed, 11 insertions(+), 7 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 189105df..779f1621 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -4,13 +4,11 @@ on: [push, pull_request] jobs: blackbox: - uses: innmind/github-workflows/.github/workflows/black-box-matrix.yml@main + uses: innmind/github-workflows/.github/workflows/black-box-matrix.yml@next coverage: - uses: innmind/github-workflows/.github/workflows/coverage-matrix.yml@main + uses: innmind/github-workflows/.github/workflows/coverage-matrix.yml@next secrets: inherit psalm: - uses: innmind/github-workflows/.github/workflows/psalm-matrix.yml@main + uses: innmind/github-workflows/.github/workflows/psalm-matrix.yml@next cs: - uses: innmind/github-workflows/.github/workflows/cs.yml@main - with: - php-version: '8.2' + uses: innmind/github-workflows/.github/workflows/cs.yml@next diff --git a/CHANGELOG.md b/CHANGELOG.md index 882e3f01..6f4d7517 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,11 @@ # Changelog +## [Unreleased] + +### Changed + +- Requires PHP `8.4` + ## 8.0.0 - 2025-04-20 ### Added diff --git a/composer.json b/composer.json index ce69df50..1ee9e71d 100644 --- a/composer.json +++ b/composer.json @@ -15,7 +15,7 @@ "issues": "http://github.com/Innmind/Http/issues" }, "require": { - "php": "~8.2", + "php": "~8.4", "innmind/url": "~4.0", "innmind/immutable": "~5.11", "innmind/filesystem": "~8.0", From fbe3587f78824ee63005474a270696a9edd9cc5b Mon Sep 17 00:00:00 2001 From: Baptiste Langlade Date: Sat, 15 Nov 2025 14:26:09 +0100 Subject: [PATCH 2/9] update dependencies --- composer.json | 17 +++++++++-------- src/Factory/Header/Factories.php | 10 +++++----- src/Header/ContentType.php | 2 +- src/Header/ContentType/Boundary.php | 6 +++--- 4 files changed, 18 insertions(+), 17 deletions(-) diff --git a/composer.json b/composer.json index 1ee9e71d..e2d30118 100644 --- a/composer.json +++ b/composer.json @@ -16,14 +16,15 @@ }, "require": { "php": "~8.4", - "innmind/url": "~4.0", - "innmind/immutable": "~5.11", - "innmind/filesystem": "~8.0", - "innmind/io": "^3.0.1", - "innmind/time-continuum": "~4.1", - "innmind/media-type": "^2.0.1", - "innmind/validation": "~2.0", - "ramsey/uuid": "~4.7" + "innmind/url": "dev-next", + "innmind/immutable": "dev-next", + "innmind/filesystem": "dev-next", + "innmind/io": "dev-next", + "innmind/time-continuum": "dev-next", + "innmind/media-type": "dev-next", + "innmind/validation": "dev-next", + "ramsey/uuid": "~4.7", + "innmind/ip": "dev-next" }, "autoload": { "psr-4": { diff --git a/src/Factory/Header/Factories.php b/src/Factory/Header/Factories.php index 8ffe2279..e16ea186 100644 --- a/src/Factory/Header/Factories.php +++ b/src/Factory/Header/Factories.php @@ -381,12 +381,12 @@ public function try(Clock $clock, Str $value): Maybe self::date => Is::string()->nonEmpty()($value->toString()) ->maybe() - ->flatMap(static fn($value) => $clock->at($value, Http::new())) + ->flatMap(static fn($value) => $clock->at($value, Http::new())->maybe()) ->map(Date::of(...)), self::expires => Is::string()->nonEmpty()($value->toString()) ->maybe() - ->flatMap(static fn($value) => $clock->at($value, Http::new())) + ->flatMap(static fn($value) => $clock->at($value, Http::new())->maybe()) ->map(Expires::of(...)), self::host => Url::maybe('http://'.$value->toString())->map(static fn($url) => Host::of( @@ -396,17 +396,17 @@ public function try(Clock $clock, Str $value): Maybe self::ifModifiedSince => Is::string()->nonEmpty()($value->toString()) ->maybe() - ->flatMap(static fn($value) => $clock->at($value, Http::new())) + ->flatMap(static fn($value) => $clock->at($value, Http::new())->maybe()) ->map(IfModifiedSince::of(...)), self::ifUnmodifiedSince => Is::string()->nonEmpty()($value->toString()) ->maybe() - ->flatMap(static fn($value) => $clock->at($value, Http::new())) + ->flatMap(static fn($value) => $clock->at($value, Http::new())->maybe()) ->map(IfUnmodifiedSince::of(...)), self::lastModified => Is::string()->nonEmpty()($value->toString()) ->maybe() - ->flatMap(static fn($value) => $clock->at($value, Http::new())) + ->flatMap(static fn($value) => $clock->at($value, Http::new())->maybe()) ->map(LastModified::of(...)), self::link => $value diff --git a/src/Header/ContentType.php b/src/Header/ContentType.php index 402cbe91..fef87233 100644 --- a/src/Header/ContentType.php +++ b/src/Header/ContentType.php @@ -33,7 +33,7 @@ public function content(): MediaType #[\Override] public function normalize(): Header { - $mediaType = new MediaType( + $mediaType = MediaType::from( $this->content->topLevel(), $this->content->subType(), $this->content->suffix(), diff --git a/src/Header/ContentType/Boundary.php b/src/Header/ContentType/Boundary.php index 66004c4d..d23db904 100644 --- a/src/Header/ContentType/Boundary.php +++ b/src/Header/ContentType/Boundary.php @@ -67,11 +67,11 @@ public function value(): string public function toHeader(): ContentType { - return ContentType::of(new MediaType\MediaType( - 'multipart', + return ContentType::of(MediaType\MediaType::from( + MediaType\TopLevel::multipart, 'form-data', '', - new MediaType\Parameter( + MediaType\Parameter::from( 'boundary', $this->value, ), From bc079875cee2c7ecbd0e3a77cd23f49e3a0b4c28 Mon Sep 17 00:00:00 2001 From: Baptiste Langlade Date: Sun, 14 Dec 2025 17:50:36 +0100 Subject: [PATCH 3/9] fix call to removed method --- composer.json | 3 ++- src/Factory/Files/Native.php | 8 +++++--- 2 files changed, 7 insertions(+), 4 deletions(-) diff --git a/composer.json b/composer.json index e2d30118..25db23d3 100644 --- a/composer.json +++ b/composer.json @@ -24,7 +24,8 @@ "innmind/media-type": "dev-next", "innmind/validation": "dev-next", "ramsey/uuid": "~4.7", - "innmind/ip": "dev-next" + "innmind/ip": "dev-next", + "innmind/mutable": "dev-next" }, "autoload": { "psr-4": { diff --git a/src/Factory/Files/Native.php b/src/Factory/Files/Native.php index 8d73ec46..ae8f1691 100644 --- a/src/Factory/Files/Native.php +++ b/src/Factory/Files/Native.php @@ -107,9 +107,11 @@ private function buildFile( */ return Either::right(File::named( $name, - Content::atPath( - $this->io, - Path::of($path), + Content::io( + $this + ->io + ->files() + ->read(Path::of($path)), ), MediaType::maybe($media)->match( static fn($media) => $media, From 1cd18647819b8745caf1280356ba56977f75eefc Mon Sep 17 00:00:00 2001 From: Baptiste Langlade Date: Sun, 14 Dec 2025 17:56:31 +0100 Subject: [PATCH 4/9] remove warnings --- tests/Header/AcceptCharsetValueTest.php | 10 +++++----- tests/Header/AcceptEncodingValueTest.php | 8 ++++---- tests/Header/AcceptLanguageValueTest.php | 8 ++++---- tests/Header/AcceptValueTest.php | 8 ++++---- tests/Header/ContentLanguageValueTest.php | 6 +++--- 5 files changed, 20 insertions(+), 20 deletions(-) diff --git a/tests/Header/AcceptCharsetValueTest.php b/tests/Header/AcceptCharsetValueTest.php index 7690f5de..d32f2ea6 100644 --- a/tests/Header/AcceptCharsetValueTest.php +++ b/tests/Header/AcceptCharsetValueTest.php @@ -23,23 +23,23 @@ public function testInterface() $this->assertSame($q, $a->quality()); $this->assertSame('unicode-1-1;q=0.8', $a->toString()); - Charset::maybe('iso-8859-5', Quality::max())->match( + $_ = Charset::maybe('iso-8859-5', Quality::max())->match( static fn($charset) => $charset, static fn() => throw new \Exception, ); - Charset::maybe('Shift_JIS', Quality::max())->match( + $_ = Charset::maybe('Shift_JIS', Quality::max())->match( static fn($charset) => $charset, static fn() => throw new \Exception, ); - Charset::maybe('ISO_8859-9:1989', Quality::max())->match( + $_ = Charset::maybe('ISO_8859-9:1989', Quality::max())->match( static fn($charset) => $charset, static fn() => throw new \Exception, ); - Charset::maybe('NF_Z_62-010_(1973)', Quality::max())->match( + $_ = Charset::maybe('NF_Z_62-010_(1973)', Quality::max())->match( static fn($charset) => $charset, static fn() => throw new \Exception, ); - Charset::maybe('*', Quality::max())->match( + $_ = Charset::maybe('*', Quality::max())->match( static fn($charset) => $charset, static fn() => throw new \Exception, ); diff --git a/tests/Header/AcceptEncodingValueTest.php b/tests/Header/AcceptEncodingValueTest.php index 37f7a22f..c11fd496 100644 --- a/tests/Header/AcceptEncodingValueTest.php +++ b/tests/Header/AcceptEncodingValueTest.php @@ -23,19 +23,19 @@ public function testInterface() $this->assertSame($q, $a->quality()); $this->assertSame('compress;q=1', $a->toString()); - Encoding::maybe('*', Quality::max())->match( + $_ = Encoding::maybe('*', Quality::max())->match( static fn($encoding) => $encoding, static fn() => throw new \Exception, ); - Encoding::maybe('compress', Quality::of(50))->match( + $_ = Encoding::maybe('compress', Quality::of(50))->match( static fn($encoding) => $encoding, static fn() => throw new \Exception, ); - Encoding::maybe('identity', Quality::of(50))->match( + $_ = Encoding::maybe('identity', Quality::of(50))->match( static fn($encoding) => $encoding, static fn() => throw new \Exception, ); - Encoding::maybe('*', Quality::of(0))->match( + $_ = Encoding::maybe('*', Quality::of(0))->match( static fn($encoding) => $encoding, static fn() => throw new \Exception, ); diff --git a/tests/Header/AcceptLanguageValueTest.php b/tests/Header/AcceptLanguageValueTest.php index b5205805..59dc6dad 100644 --- a/tests/Header/AcceptLanguageValueTest.php +++ b/tests/Header/AcceptLanguageValueTest.php @@ -23,19 +23,19 @@ public function testInterface() $this->assertSame($q, $a->quality()); $this->assertSame('en-gb;q=0.8', $a->toString()); - Language::maybe('fr', Quality::max())->match( + $_ = Language::maybe('fr', Quality::max())->match( static fn($language) => $language, static fn() => throw new \Exception, ); - Language::maybe('fr-FR', Quality::max())->match( + $_ = Language::maybe('fr-FR', Quality::max())->match( static fn($language) => $language, static fn() => throw new \Exception, ); - Language::maybe('sgn-CH-DE', Quality::max())->match( + $_ = Language::maybe('sgn-CH-DE', Quality::max())->match( static fn($language) => $language, static fn() => throw new \Exception, ); - Language::maybe('*', Quality::max())->match( + $_ = Language::maybe('*', Quality::max())->match( static fn($language) => $language, static fn() => throw new \Exception, ); diff --git a/tests/Header/AcceptValueTest.php b/tests/Header/AcceptValueTest.php index 6da58996..ee3c876e 100644 --- a/tests/Header/AcceptValueTest.php +++ b/tests/Header/AcceptValueTest.php @@ -33,28 +33,28 @@ public function testInterface() )); $this->assertSame('text/x-c;q=0.8', $a->toString()); - MediaType::maybe( + $_ = MediaType::maybe( '*', '*', )->match( static fn($mediaType) => $mediaType, static fn() => throw new \Exception, ); - MediaType::maybe( + $_ = MediaType::maybe( 'application', '*', )->match( static fn($mediaType) => $mediaType, static fn() => throw new \Exception, ); - MediaType::maybe( + $_ = MediaType::maybe( 'application', 'octet-stream', )->match( static fn($mediaType) => $mediaType, static fn() => throw new \Exception, ); - MediaType::maybe( + $_ = MediaType::maybe( 'application', 'octet-stream', Quality::of(40)->toParameter(), diff --git a/tests/Header/ContentLanguageValueTest.php b/tests/Header/ContentLanguageValueTest.php index c7208f3c..49796b0d 100644 --- a/tests/Header/ContentLanguageValueTest.php +++ b/tests/Header/ContentLanguageValueTest.php @@ -19,15 +19,15 @@ public function testInterface() $this->assertInstanceOf(Language::class, $a); $this->assertSame('en-gb', $a->toString()); - Language::maybe('fr')->match( + $_ = Language::maybe('fr')->match( static fn($language) => $language, static fn() => throw new \Exception, ); - Language::maybe('fr-FR')->match( + $_ = Language::maybe('fr-FR')->match( static fn($language) => $language, static fn() => throw new \Exception, ); - Language::maybe('sgn-CH-DE')->match( + $_ = Language::maybe('sgn-CH-DE')->match( static fn($language) => $language, static fn() => throw new \Exception, ); From 522b7222f89dc3ba5b895bb74ea7b0c4f130bd1d Mon Sep 17 00:00:00 2001 From: Baptiste Langlade Date: Sun, 14 Dec 2025 18:07:33 +0100 Subject: [PATCH 5/9] bump blackbox --- composer.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/composer.json b/composer.json index 25db23d3..d801e691 100644 --- a/composer.json +++ b/composer.json @@ -39,7 +39,7 @@ }, "require-dev": { "innmind/static-analysis": "^1.2.1", - "innmind/black-box": "~6.1", + "innmind/black-box": "~6.5", "innmind/coding-standard": "~2.0", "symfony/process": "^6.2" } From 2c19683c1b425e29da1c486dceeb07189fac6179 Mon Sep 17 00:00:00 2001 From: Baptiste Langlade Date: Sun, 1 Feb 2026 18:30:11 +0100 Subject: [PATCH 6/9] tag dependencies --- .github/workflows/ci.yml | 8 ++++---- composer.json | 20 +++++++++----------- src/Content/Multipart/Data.php | 2 +- src/Content/Multipart/File.php | 2 +- 4 files changed, 15 insertions(+), 17 deletions(-) diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 779f1621..2f3eecb7 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -4,11 +4,11 @@ on: [push, pull_request] jobs: blackbox: - uses: innmind/github-workflows/.github/workflows/black-box-matrix.yml@next + uses: innmind/github-workflows/.github/workflows/black-box-matrix.yml@main coverage: - uses: innmind/github-workflows/.github/workflows/coverage-matrix.yml@next + uses: innmind/github-workflows/.github/workflows/coverage-matrix.yml@main secrets: inherit psalm: - uses: innmind/github-workflows/.github/workflows/psalm-matrix.yml@next + uses: innmind/github-workflows/.github/workflows/psalm-matrix.yml@main cs: - uses: innmind/github-workflows/.github/workflows/cs.yml@next + uses: innmind/github-workflows/.github/workflows/cs.yml@main diff --git a/composer.json b/composer.json index d801e691..0604dbda 100644 --- a/composer.json +++ b/composer.json @@ -16,16 +16,14 @@ }, "require": { "php": "~8.4", - "innmind/url": "dev-next", - "innmind/immutable": "dev-next", - "innmind/filesystem": "dev-next", - "innmind/io": "dev-next", - "innmind/time-continuum": "dev-next", - "innmind/media-type": "dev-next", - "innmind/validation": "dev-next", - "ramsey/uuid": "~4.7", - "innmind/ip": "dev-next", - "innmind/mutable": "dev-next" + "innmind/url": "~5.0", + "innmind/immutable": "~6.0", + "innmind/filesystem": "~9.0", + "innmind/io": "~4.0", + "innmind/time-continuum": "~5.0", + "innmind/media-type": "~3.0", + "innmind/validation": "~3.0", + "ramsey/uuid": "~4.7" }, "autoload": { "psr-4": { @@ -38,7 +36,7 @@ } }, "require-dev": { - "innmind/static-analysis": "^1.2.1", + "innmind/static-analysis": "~1.3", "innmind/black-box": "~6.5", "innmind/coding-standard": "~2.0", "symfony/process": "^6.2" diff --git a/src/Content/Multipart/Data.php b/src/Content/Multipart/Data.php index d1259021..9d7c11cb 100644 --- a/src/Content/Multipart/Data.php +++ b/src/Content/Multipart/Data.php @@ -41,7 +41,7 @@ public function size(): Maybe return Maybe::just( $this ->chunks() - ->fold(new Concat) + ->fold(Concat::monoid) ->toEncoding(Str\Encoding::ascii) ->length(), ); diff --git a/src/Content/Multipart/File.php b/src/Content/Multipart/File.php index 1587b527..84648328 100644 --- a/src/Content/Multipart/File.php +++ b/src/Content/Multipart/File.php @@ -41,7 +41,7 @@ public function size(): Maybe { $headers = $this ->headers() - ->fold(new Concat) + ->fold(Concat::monoid) ->toEncoding(Str\Encoding::ascii) ->length(); From 020e381a157d68d2522e6d5b044dad928d63af52 Mon Sep 17 00:00:00 2001 From: Baptiste Langlade Date: Sun, 1 Feb 2026 18:48:17 +0100 Subject: [PATCH 7/9] replace innmind/time-continuum by innmind/time --- CHANGELOG.md | 1 + composer.json | 2 +- src/Factory/Header/Factories.php | 4 ++-- src/Factory/Header/Factory.php | 2 +- src/Factory/Headers/Native.php | 2 +- src/Factory/HeadersFactory.php | 2 +- src/Factory/ServerRequestFactory.php | 2 +- src/Header/Date.php | 12 ++++++------ src/Header/Expires.php | 12 ++++++------ src/Header/IfModifiedSince.php | 12 ++++++------ src/Header/IfUnmodifiedSince.php | 12 ++++++------ src/Header/LastModified.php | 12 ++++++------ src/Header/SetCookie/Expires.php | 12 ++++++------ src/Response/Sender/Native.php | 2 +- src/{TimeContinuum => Time}/Format/Http.php | 4 ++-- tests/Factory/Header/AcceptCharsetFactoryTest.php | 2 +- tests/Factory/Header/AcceptEncodingFactoryTest.php | 2 +- tests/Factory/Header/AcceptFactoryTest.php | 2 +- tests/Factory/Header/AcceptLanguageFactoryTest.php | 2 +- tests/Factory/Header/AcceptRangesFactoryTest.php | 2 +- tests/Factory/Header/AgeFactoryTest.php | 2 +- tests/Factory/Header/AllowFactoryTest.php | 2 +- tests/Factory/Header/AuthorizationFactoryTest.php | 2 +- tests/Factory/Header/CacheControlFactoryTest.php | 2 +- tests/Factory/Header/ContentEncodingFactoryTest.php | 2 +- tests/Factory/Header/ContentLanguageFactoryTest.php | 2 +- tests/Factory/Header/ContentLengthFactoryTest.php | 2 +- tests/Factory/Header/ContentLocationFactoryTest.php | 2 +- tests/Factory/Header/ContentRangeFactoryTest.php | 2 +- tests/Factory/Header/ContentTypeFactoryTest.php | 2 +- tests/Factory/Header/CookieFactoryTest.php | 2 +- tests/Factory/Header/DateFactoryTest.php | 2 +- tests/Factory/Header/ExpiresFactoryTest.php | 2 +- tests/Factory/Header/HeadersFactoryTest.php | 2 +- tests/Factory/Header/HostFactoryTest.php | 2 +- tests/Factory/Header/IfModifiedSinceFactoryTest.php | 2 +- .../Factory/Header/IfUnmodifiedSinceFactoryTest.php | 2 +- tests/Factory/Header/LastModifiedFactoryTest.php | 2 +- tests/Factory/Header/LinkFactoryTest.php | 2 +- tests/Factory/Header/LocationFactoryTest.php | 2 +- tests/Factory/Header/RangeFactoryTest.php | 2 +- tests/Factory/Header/ReferrerFactoryTest.php | 2 +- tests/Factory/Header/TryFactoryTest.php | 2 +- .../ServerRequest/ServerRequestFactoryTest.php | 2 +- tests/Header/CookieParameter/ExpiresTest.php | 4 ++-- tests/Header/DateTest.php | 6 +++--- tests/Header/ExpiresTest.php | 6 +++--- tests/Header/IfModifiedSinceTest.php | 6 +++--- tests/Header/IfUnmodifiedSinceTest.php | 6 +++--- tests/Header/LastModifiedTest.php | 6 +++--- 50 files changed, 93 insertions(+), 92 deletions(-) rename src/{TimeContinuum => Time}/Format/Http.php (71%) diff --git a/CHANGELOG.md b/CHANGELOG.md index 6f4d7517..4eabce0d 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,7 @@ ### Changed - Requires PHP `8.4` +- Requires `innmind/time:~1.0` ## 8.0.0 - 2025-04-20 diff --git a/composer.json b/composer.json index 0604dbda..563733b5 100644 --- a/composer.json +++ b/composer.json @@ -20,7 +20,7 @@ "innmind/immutable": "~6.0", "innmind/filesystem": "~9.0", "innmind/io": "~4.0", - "innmind/time-continuum": "~5.0", + "innmind/time": "~1.0", "innmind/media-type": "~3.0", "innmind/validation": "~3.0", "ramsey/uuid": "~4.7" diff --git a/src/Factory/Header/Factories.php b/src/Factory/Header/Factories.php index e16ea186..c0ab65bc 100644 --- a/src/Factory/Header/Factories.php +++ b/src/Factory/Header/Factories.php @@ -35,10 +35,10 @@ Header\Referrer, Header\Parameter, Header\Parameter\Quality, - TimeContinuum\Format\Http, + Time\Format\Http, Method, }; -use Innmind\TimeContinuum\Clock; +use Innmind\Time\Clock; use Innmind\Validation\Is; use Innmind\MediaType\MediaType; use Innmind\Url\Url; diff --git a/src/Factory/Header/Factory.php b/src/Factory/Header/Factory.php index 23c37883..0511da71 100644 --- a/src/Factory/Header/Factory.php +++ b/src/Factory/Header/Factory.php @@ -7,7 +7,7 @@ Header, Header\Value, }; -use Innmind\TimeContinuum\Clock; +use Innmind\Time\Clock; use Innmind\Immutable\Str; /** diff --git a/src/Factory/Headers/Native.php b/src/Factory/Headers/Native.php index 9b482451..0b69d676 100644 --- a/src/Factory/Headers/Native.php +++ b/src/Factory/Headers/Native.php @@ -7,7 +7,7 @@ Factory\Header\Factory, Headers, }; -use Innmind\TimeContinuum\Clock; +use Innmind\Time\Clock; use Innmind\Immutable\Str; /** diff --git a/src/Factory/HeadersFactory.php b/src/Factory/HeadersFactory.php index 111acc86..20684443 100644 --- a/src/Factory/HeadersFactory.php +++ b/src/Factory/HeadersFactory.php @@ -7,7 +7,7 @@ Headers, Factory\Headers\Native, }; -use Innmind\TimeContinuum\Clock; +use Innmind\Time\Clock; /** * @psalm-immutable diff --git a/src/Factory/ServerRequestFactory.php b/src/Factory/ServerRequestFactory.php index 9c4e337f..7fb75a38 100644 --- a/src/Factory/ServerRequestFactory.php +++ b/src/Factory/ServerRequestFactory.php @@ -9,7 +9,7 @@ ProtocolVersion, Factory, }; -use Innmind\TimeContinuum\Clock; +use Innmind\Time\Clock; use Innmind\Filesystem\File\Content; use Innmind\Url\Url; use Innmind\IO\IO; diff --git a/src/Header/Date.php b/src/Header/Date.php index 3973f334..f7664f95 100644 --- a/src/Header/Date.php +++ b/src/Header/Date.php @@ -5,10 +5,10 @@ use Innmind\Http\{ Header, - TimeContinuum\Format\Http, + Time\Format\Http, }; -use Innmind\TimeContinuum\{ - PointInTime, +use Innmind\Time\{ + Point, Offset, }; @@ -18,19 +18,19 @@ final class Date implements Custom { private function __construct( - private PointInTime $point, + private Point $point, ) { } /** * @psalm-pure */ - public static function of(PointInTime $point): self + public static function of(Point $point): self { return new self($point); } - public function date(): PointInTime + public function date(): Point { return $this->point; } diff --git a/src/Header/Expires.php b/src/Header/Expires.php index d9f5f13d..2dc62fd1 100644 --- a/src/Header/Expires.php +++ b/src/Header/Expires.php @@ -5,10 +5,10 @@ use Innmind\Http\{ Header, - TimeContinuum\Format\Http, + Time\Format\Http, }; -use Innmind\TimeContinuum\{ - PointInTime, +use Innmind\Time\{ + Point, Offset, }; @@ -18,19 +18,19 @@ final class Expires implements Custom { private function __construct( - private PointInTime $point, + private Point $point, ) { } /** * @psalm-pure */ - public static function of(PointInTime $point): self + public static function of(Point $point): self { return new self($point); } - public function date(): PointInTime + public function date(): Point { return $this->point; } diff --git a/src/Header/IfModifiedSince.php b/src/Header/IfModifiedSince.php index 63c0c57b..19cc8226 100644 --- a/src/Header/IfModifiedSince.php +++ b/src/Header/IfModifiedSince.php @@ -5,10 +5,10 @@ use Innmind\Http\{ Header, - TimeContinuum\Format\Http, + Time\Format\Http, }; -use Innmind\TimeContinuum\{ - PointInTime, +use Innmind\Time\{ + Point, Offset, }; @@ -18,19 +18,19 @@ final class IfModifiedSince implements Custom { private function __construct( - private PointInTime $point, + private Point $point, ) { } /** * @psalm-pure */ - public static function of(PointInTime $point): self + public static function of(Point $point): self { return new self($point); } - public function date(): PointInTime + public function date(): Point { return $this->point; } diff --git a/src/Header/IfUnmodifiedSince.php b/src/Header/IfUnmodifiedSince.php index 1c57a8fd..3110fd8d 100644 --- a/src/Header/IfUnmodifiedSince.php +++ b/src/Header/IfUnmodifiedSince.php @@ -5,10 +5,10 @@ use Innmind\Http\{ Header, - TimeContinuum\Format\Http, + Time\Format\Http, }; -use Innmind\TimeContinuum\{ - PointInTime, +use Innmind\Time\{ + Point, Offset, }; @@ -18,19 +18,19 @@ final class IfUnmodifiedSince implements Custom { private function __construct( - private PointInTime $point, + private Point $point, ) { } /** * @psalm-pure */ - public static function of(PointInTime $point): self + public static function of(Point $point): self { return new self($point); } - public function date(): PointInTime + public function date(): Point { return $this->point; } diff --git a/src/Header/LastModified.php b/src/Header/LastModified.php index 9d6abdc8..81d49edd 100644 --- a/src/Header/LastModified.php +++ b/src/Header/LastModified.php @@ -5,10 +5,10 @@ use Innmind\Http\{ Header, - TimeContinuum\Format\Http, + Time\Format\Http, }; -use Innmind\TimeContinuum\{ - PointInTime, +use Innmind\Time\{ + Point, Offset, }; @@ -18,19 +18,19 @@ final class LastModified implements Custom { private function __construct( - private PointInTime $point, + private Point $point, ) { } /** * @psalm-pure */ - public static function of(PointInTime $point): self + public static function of(Point $point): self { return new self($point); } - public function date(): PointInTime + public function date(): Point { return $this->point; } diff --git a/src/Header/SetCookie/Expires.php b/src/Header/SetCookie/Expires.php index 9dd0710f..93d67878 100644 --- a/src/Header/SetCookie/Expires.php +++ b/src/Header/SetCookie/Expires.php @@ -5,10 +5,10 @@ use Innmind\Http\{ Header\Parameter, - TimeContinuum\Format\Http, + Time\Format\Http, }; -use Innmind\TimeContinuum\{ - PointInTime, +use Innmind\Time\{ + Point, Offset, }; @@ -18,19 +18,19 @@ final class Expires { private function __construct( - private PointInTime $date, + private Point $date, ) { } /** * @psalm-pure */ - public static function at(PointInTime $date): self + public static function at(Point $date): self { return new self($date->changeOffset(Offset::utc())); } - public function date(): PointInTime + public function date(): Point { return $this->date; } diff --git a/src/Response/Sender/Native.php b/src/Response/Sender/Native.php index d7befdd0..77404969 100644 --- a/src/Response/Sender/Native.php +++ b/src/Response/Sender/Native.php @@ -10,7 +10,7 @@ Header\SetCookie, Exception\LogicException, }; -use Innmind\TimeContinuum\{ +use Innmind\Time\{ Clock, Format, }; diff --git a/src/TimeContinuum/Format/Http.php b/src/Time/Format/Http.php similarity index 71% rename from src/TimeContinuum/Format/Http.php rename to src/Time/Format/Http.php index 6e591ae2..506a29c8 100644 --- a/src/TimeContinuum/Format/Http.php +++ b/src/Time/Format/Http.php @@ -1,9 +1,9 @@ Date: Sun, 1 Feb 2026 18:48:30 +0100 Subject: [PATCH 8/9] add missing line in changelog --- CHANGELOG.md | 1 + 1 file changed, 1 insertion(+) diff --git a/CHANGELOG.md b/CHANGELOG.md index 4eabce0d..a490095f 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -5,6 +5,7 @@ ### Changed - Requires PHP `8.4` +- Requires `innmind/filesystem:~9.0` - Requires `innmind/time:~1.0` ## 8.0.0 - 2025-04-20 From 311005799025c7ad6b8c1631505ae74cfd69087a Mon Sep 17 00:00:00 2001 From: Baptiste Langlade Date: Sun, 1 Feb 2026 18:48:39 +0100 Subject: [PATCH 9/9] CS --- src/Header/Accept/MediaType.php | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/src/Header/Accept/MediaType.php b/src/Header/Accept/MediaType.php index 3888c8a9..82c701f7 100644 --- a/src/Header/Accept/MediaType.php +++ b/src/Header/Accept/MediaType.php @@ -3,9 +3,7 @@ namespace Innmind\Http\Header\Accept; -use Innmind\Http\{ - Header\Parameter, -}; +use Innmind\Http\Header\Parameter; use Innmind\Immutable\{ Str, Map,