Automated formatting changes

This commit is contained in:
Formatter Bot 2020-11-24 16:35:09 +00:00
parent 7bd4b0878e
commit 2b8850f9b9
3 changed files with 5 additions and 5 deletions

View File

@ -85,7 +85,7 @@ final class ApiController extends Controller
*/ */
private function createItemFromRequest(RequestAbstract $request) : Item private function createItemFromRequest(RequestAbstract $request) : Item
{ {
$item = new Item(); $item = new Item();
$item->number = $request->getData('number') ?? ''; $item->number = $request->getData('number') ?? '';
return $item; return $item;
@ -459,7 +459,7 @@ final class ApiController extends Controller
*/ */
private function createItemL11nTypeFromRequest(RequestAbstract $request) : ItemL11nType private function createItemL11nTypeFromRequest(RequestAbstract $request) : ItemL11nType
{ {
$itemL11nType = new ItemL11nType(); $itemL11nType = new ItemL11nType();
$itemL11nType->title = (string) ($request->getData('title') ?? ''); $itemL11nType->title = (string) ($request->getData('title') ?? '');
return $itemL11nType; return $itemL11nType;

View File

@ -114,7 +114,7 @@ class ItemAttributeType implements \JsonSerializable, ArrayableInterface
} elseif ($this->l11n instanceof ItemAttributeTypeL11n && \is_string($l11n)) { } elseif ($this->l11n instanceof ItemAttributeTypeL11n && \is_string($l11n)) {
$this->l11n->title = $l11n; $this->l11n->title = $l11n;
} elseif (\is_string($l11n)) { } elseif (\is_string($l11n)) {
$this->l11n = new ItemAttributeTypeL11n(); $this->l11n = new ItemAttributeTypeL11n();
$this->l11n->title = $l11n; $this->l11n->title = $l11n;
$this->l11n->setLanguage($lang); $this->l11n->setLanguage($lang);
} }

View File

@ -28,7 +28,7 @@ class ItemMapperTest extends \PHPUnit\Framework\TestCase
*/ */
public function testCR() : void public function testCR() : void
{ {
$item = new Item(); $item = new Item();
$item->number = '123456789'; $item->number = '123456789';
$id = ItemMapper::create($item); $id = ItemMapper::create($item);
@ -44,7 +44,7 @@ class ItemMapperTest extends \PHPUnit\Framework\TestCase
public function testItemVolume() : void public function testItemVolume() : void
{ {
for ($i = 0; $i < 100; ++$i) { for ($i = 0; $i < 100; ++$i) {
$item = new Item(); $item = new Item();
$item->number = (string) \mt_rand(100000, 999999); $item->number = (string) \mt_rand(100000, 999999);
ItemMapper::create($item); ItemMapper::create($item);