Releases: nimbly/Capsule
Releases · nimbly/Capsule
Release 3.0
Updates
- Migrating
ResponseStatus
class and constants to an Enum type. - Creating an
HttpMethod
Enum - Adding class and constructor comments.
- Revamping file upload code - specifically on parsing the $_FILES superglobal.
- Supporting nested file uploads
- Expanded unit tests and coverage
Breaking Changes
ResponseStatus::getPhrase()
is now an instance method (it is no longer static.) With an instance ofResponseStatus
you can call thegetPhrase()
method. Example:
$status = ResponseStatus::NOT_FOUND;
$status->getPhrase();
Release 2.0.2
Note
This will be the last 2.x release of Capsule (barring security or bug fixes). Active feature development will be moved to the 3.x release.
Fixes
- Fixed uploaded file moving test for Windows
Updates
- Adding support for
psr/http-message
2.0
Release 2.0.1
Fixes
- Port number was always being returned in authority if a port number was supplied. This was breaking convention in only using port number if the port is non-standard for the given scheme (http vs https.)
- Fixing formatting issues in code.
Release 2.0
Features
- Support for PHP 8.x, leveraging features from 8.0
- Adding
createFromString
method inStreamFactory
- Adding
provide
property in composer file forpsr/http-message-implementation
andpsr/http-factory-implementation
- A lot of code and comment cleanup, standardizing formatting
- Stricter type hinting in constructors and methods where possible (using union type)
- Tightening up
Uri::__toString()
andUri::getAuthority()
methods, fixing long standing bugs
Breaking changes
- Removing support for PHP 7.x
- Moving namespace to
Nimbly\Capsule
- Removing warning suppression (
@
) when making calls tofopen
Release 1.1.2
Fixes
- In accordance with PSR,
__toString()
andgetContents()
methods on theResourceStream
will attempt to safelyrewind
the underlying stream.
Release 1.1.1
Fixes
- MessageAbstract::withHeader() now treats header names as case insensitive and will correctly overwrite the header.
Release 1.1
Features
- Adding PHP 8.0 support.
Breaking changes
- Dropping PHP 7.2 support.
ServerRequestFactory::createServerRequestFromPsr7()
is now a public static method.
Release 1.0
Updates
- Helper methods on
ServerRequest
to access parsed body, query, and uploaded file parameters. See README for more information. - Full PSR-17 Factory support.
- Query params automatically merged into ServerRequest from URI instance.
ext-json
no longer required.- Additional test coverage across entire package.
Fixes
ResourceStream
properly detaches as well as properly throwingRuntimeException
on certain methods as described in interface.
Breaking changes
- Response constructor signature change.
- ServerRequest::createFromGlobals() moved to ServerRequestFactory::createFromGlobals().
- FileStream class renamed to ResourceStream.
- ServerRequest will no longer attempt to automatically parse the request body. Best practice is to create a Middleware layer to handle request body parsing and assigning to Request instance via
$request->withParsedBody($parsedBody);
Release 0.11
Fixes
- Custom Response reason phrases are now respected
- Better support for static analyzers methods that return new instance of self
Release 0.10
Updates
- Adding
Factory::createServerRequestFromPsr7()
method to convert any other PSR-7 ServerRequestInterface instance into a Capsule specific ServerRequest.
Fixes
- Cleaning up code that attempts to automatically parse the ServerRequest body
Breaking changes
None