1
0
mirror of https://github.com/Intervention/image.git synced 2025-01-17 04:08:14 +01:00

Rename ImageManager::make to ImageManager::read

This commit is contained in:
Oliver Vogel 2023-10-01 09:59:05 +02:00
parent 635567e9c2
commit 764c6f3843
3 changed files with 6 additions and 6 deletions

View File

@ -20,7 +20,7 @@ Intervention Image is a **image handling and manipulation library written in PHP
$manager = new ImageManager('gd')
// open an image file
$image = $manager->make('images/example.gif');
$image = $manager->read('images/example.gif');
// resize image instance
$image->resize(height: 300);

View File

@ -32,7 +32,7 @@ class ImageManager
* @param mixed $source
* @return ImageInterface
*/
public function make($source): ImageInterface
public function read($source): ImageInterface
{
return $this->resolveDriverClass('InputHandler')->handle($source);
}

View File

@ -25,10 +25,10 @@ class ImageManagerTest extends TestCase
}
/** @requires extension gd */
public function testMakeGd()
public function testReadGd()
{
$manager = new ImageManager('gd');
$image = $manager->make(__DIR__ . '/images/red.gif');
$image = $manager->read(__DIR__ . '/images/red.gif');
$this->assertInstanceOf(ImageInterface::class, $image);
}
@ -41,10 +41,10 @@ class ImageManagerTest extends TestCase
}
/** @requires extension imagick */
public function testMakeImagick()
public function testReadImagick()
{
$manager = new ImageManager('imagick');
$image = $manager->make(__DIR__ . '/images/red.gif');
$image = $manager->read(__DIR__ . '/images/red.gif');
$this->assertInstanceOf(ImageInterface::class, $image);
}
}