mirror of
https://github.com/Intervention/image.git
synced 2025-08-26 07:14:31 +02:00
Add mixed type hints
This commit is contained in:
@@ -47,7 +47,7 @@ class Frame extends AbstractFrame implements FrameInterface
|
||||
*
|
||||
* @see FrameInterface::setNative()
|
||||
*/
|
||||
public function setNative($native): FrameInterface
|
||||
public function setNative(mixed $native): FrameInterface
|
||||
{
|
||||
$this->native = $native;
|
||||
|
||||
|
@@ -50,7 +50,7 @@ class Core implements CoreInterface, Iterator
|
||||
*
|
||||
* @see CollectionInterface::push()
|
||||
*/
|
||||
public function push($item): CollectionInterface
|
||||
public function push(mixed $item): CollectionInterface
|
||||
{
|
||||
return $this->add($item);
|
||||
}
|
||||
@@ -60,7 +60,7 @@ class Core implements CoreInterface, Iterator
|
||||
*
|
||||
* @see CollectionInterface::get()
|
||||
*/
|
||||
public function get(int|string $key, $default = null): mixed
|
||||
public function get(int|string $key, mixed $default = null): mixed
|
||||
{
|
||||
try {
|
||||
$this->imagick->setIteratorIndex($key);
|
||||
@@ -76,7 +76,7 @@ class Core implements CoreInterface, Iterator
|
||||
*
|
||||
* @see CollectionInterface::getAtPosition()
|
||||
*/
|
||||
public function getAtPosition(int $key = 0, $default = null): mixed
|
||||
public function getAtPosition(int $key = 0, mixed $default = null): mixed
|
||||
{
|
||||
return $this->get($key, $default);
|
||||
}
|
||||
|
@@ -46,7 +46,7 @@ class Frame extends AbstractFrame implements FrameInterface
|
||||
*
|
||||
* @see DriverInterface::setNative()
|
||||
*/
|
||||
public function setNative($native): FrameInterface
|
||||
public function setNative(mixed $native): FrameInterface
|
||||
{
|
||||
$this->native = $native;
|
||||
|
||||
|
@@ -89,7 +89,7 @@ class InputHandler implements InputHandlerInterface
|
||||
*
|
||||
* @see InputHandlerInterface::handle()
|
||||
*/
|
||||
public function handle($input): ImageInterface|ColorInterface
|
||||
public function handle(mixed $input): ImageInterface|ColorInterface
|
||||
{
|
||||
foreach ($this->decoders as $decoder) {
|
||||
try {
|
||||
|
Reference in New Issue
Block a user