Skip to content

Commit 7f4668e

Browse files
committed
31606:Fixed static test failure
1 parent 12ecbb3 commit 7f4668e

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed

app/code/Magento/Sales/Test/Fixture/InvoiceComment.php

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,8 @@
11
<?php
2-
2+
/**
3+
* Copyright © Magento, Inc. All rights reserved.
4+
* See COPYING.txt for license details.
5+
*/
36
namespace Magento\Sales\Test\Fixture;
47

58
use Magento\Framework\DataObject;
@@ -46,10 +49,9 @@ public function __construct(
4649
public function apply(array $data = []): ?DataObject
4750
{
4851
$service = $this->serviceFactory->create(InvoiceCommentRepositoryInterface::class, 'save');
52+
$invoiceComment = $service->execute($this->prepareData($data));
4953

50-
$invoiceCommentId = $service->execute($this->prepareData($data));
51-
52-
return $this->invoiceCommentRepository->get($invoiceCommentId->getId());
54+
return $this->invoiceCommentRepository->get($invoiceComment->getId());
5355
}
5456

5557
public function revert(DataObject $data): void

0 commit comments

Comments
 (0)