mirror of
https://github.com/Intervention/image.git
synced 2025-08-06 13:56:30 +02:00
Remove unnecessary brackets
This commit is contained in:
@@ -70,7 +70,7 @@ abstract class AbstractDriver implements DriverInterface
|
|||||||
}
|
}
|
||||||
|
|
||||||
// return directly and only attach driver if object is already specialized
|
// return directly and only attach driver if object is already specialized
|
||||||
if (($object instanceof SpecializedInterface)) {
|
if ($object instanceof SpecializedInterface) {
|
||||||
$object->setDriver($this);
|
$object->setDriver($this);
|
||||||
|
|
||||||
return $object;
|
return $object;
|
||||||
@@ -88,7 +88,7 @@ abstract class AbstractDriver implements DriverInterface
|
|||||||
}
|
}
|
||||||
|
|
||||||
// create a driver specialized object with the specializable properties of generic object
|
// create a driver specialized object with the specializable properties of generic object
|
||||||
$specialized = (new $specialized_classname(...$object->specializable()));
|
$specialized = new $specialized_classname(...$object->specializable());
|
||||||
|
|
||||||
// attach driver
|
// attach driver
|
||||||
return $specialized->setDriver($this);
|
return $specialized->setDriver($this);
|
||||||
|
@@ -163,10 +163,10 @@ abstract class AbstractFontProcessor implements FontProcessorInterface
|
|||||||
protected function buildPivot(TextBlock $block, FontInterface $font, PointInterface $position): PointInterface
|
protected function buildPivot(TextBlock $block, FontInterface $font, PointInterface $position): PointInterface
|
||||||
{
|
{
|
||||||
// bounding box
|
// bounding box
|
||||||
$box = (new Rectangle(
|
$box = new Rectangle(
|
||||||
$this->boxSize((string) $block->longestLine(), $font)->width(),
|
$this->boxSize((string) $block->longestLine(), $font)->width(),
|
||||||
$this->leading($font) * ($block->count() - 1) + $this->capHeight($font)
|
$this->leading($font) * ($block->count() - 1) + $this->capHeight($font)
|
||||||
));
|
);
|
||||||
|
|
||||||
// set position
|
// set position
|
||||||
$box->setPivot($position);
|
$box->setPivot($position);
|
||||||
|
Reference in New Issue
Block a user