Katy Ereira - #PHPUK25 - @
[email protected]
/**
* Creates a new order for the
* basket, then emits an event and
* emails the merchant.
*
* New Order returned if success.
*
* Else, returns an error string.
*/
public function placeOrder(
Basket $basket
): mixed;
/**
* Creates a new order for the
* basket, then emits an event and
* emails the merchant.
*
*
*
* @throws OrderPlacementFailed
*/
public function placeOrder(
Basket $basket
): Order;
Donʼt do that Do this
/**
* Creates a new order for the
* basket, then emits an event and
* emails the merchant.
*
* New Order returned if success.
*
* Else, returns an error string.
*/
public function placeOrder(
Basket $basket
): mixed;