Skip to content

Commit 5f2769b

Browse files
The Checkout interface extends ArrayAccess and Shippable
1 parent bb272b1 commit 5f2769b

File tree

4 files changed

+6
-5
lines changed

4 files changed

+6
-5
lines changed

Changelog.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,7 @@
6060
- Added the `Address` DTO class (implements the `Address` interface)
6161
- Added the `AdjusterAliases` class that for decoupling FQCNs from the database
6262
- Added automatic mapping of adjuster FQCN <-> aliases when saving an adjustment into the DB and when calling the `getAdjuster()` method
63+
- BC: The `Checkout` interface now extends the `ArrayAccess` and the `Shippable` interfaces (until here, only the concrete classes have implementation it)
6364
- BC: Added cart and order item models to the Relation morph map: the `adjustable_type` field in the `adjustments` table needs to be converted!
6465
- BC: Added the `?CheckoutSubject` return type to the `getCart()` method of the `Checkout` interface
6566
- BC: Changed `Checkout::getShippingAddress()` return type to be nullable

src/Checkout/Changelog.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,7 @@
1313
- Changed minimum Laravel version to v10.38.2
1414
- Changed minimal Enum requirement to v4.2
1515
- Added the `BillpayerChanged` event
16+
- BC: The `Checkout` interface now extends the `ArrayAccess` and the `Shippable` interfaces (until here, only the concrete classes have implementation it)
1617
- BC: Added the `?CheckoutSubject` return type to the `getCart()` method of the `Checkout` interface
1718
- BC: The unused `$config` parameter has been removed from the `RequestStore` checkout driver constructor
1819
- BC: Changed `Checkout::getShippingAddress()` return type to be nullable

src/Checkout/CheckoutManager.php

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,11 +23,8 @@
2323
use Vanilo\Contracts\CheckoutSubject;
2424
use Vanilo\Contracts\DetailedAmount;
2525
use Vanilo\Contracts\Dimension;
26-
use Vanilo\Contracts\Shippable;
2726

28-
/** @todo Remove `ArrayAccess` and make the Checkout interface to extend ArrayAccess in v4 */
29-
/** @todo Remove `Shippable` and make the Checkout interface to extend Shippable in v4 */
30-
class CheckoutManager implements CheckoutContract, Shippable, \ArrayAccess
27+
class CheckoutManager implements CheckoutContract
3128
{
3229
use ForwardsCalls;
3330

src/Checkout/Contracts/Checkout.php

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,12 +14,14 @@
1414

1515
namespace Vanilo\Checkout\Contracts;
1616

17+
use ArrayAccess;
1718
use Vanilo\Contracts\Address;
1819
use Vanilo\Contracts\Billpayer;
1920
use Vanilo\Contracts\CheckoutSubject;
2021
use Vanilo\Contracts\DetailedAmount;
22+
use Vanilo\Contracts\Shippable;
2123

22-
interface Checkout
24+
interface Checkout extends Shippable, ArrayAccess
2325
{
2426
public function getCart(): ?CheckoutSubject;
2527

0 commit comments

Comments
 (0)