mirror of
https://github.com/woocommerce/woocommerce-paypal-payments.git
synced 2025-09-01 07:02:48 +08:00
downgrade plugin to php 7.0
This commit is contained in:
parent
5e011b4f95
commit
c5899d915c
61 changed files with 419 additions and 368 deletions
|
@ -14,7 +14,7 @@ use Inpsyde\PayPalCommerce\Session\Cancellation\CancelController;
|
|||
use Inpsyde\PayPalCommerce\Session\Cancellation\CancelView;
|
||||
|
||||
return array(
|
||||
'session.handler' => function ( ContainerInterface $container ) : SessionHandler {
|
||||
'session.handler' => function ( $container ) : SessionHandler {
|
||||
|
||||
if ( is_null( WC()->session ) ) {
|
||||
return new SessionHandler();
|
||||
|
@ -27,10 +27,10 @@ return array(
|
|||
WC()->session->set( SessionHandler::ID, $session_handler );
|
||||
return $session_handler;
|
||||
},
|
||||
'session.cancellation.view' => function ( ContainerInterface $container ) : CancelView {
|
||||
'session.cancellation.view' => function ( $container ) : CancelView {
|
||||
return new CancelView();
|
||||
},
|
||||
'session.cancellation.controller' => function ( ContainerInterface $container ) : CancelController {
|
||||
'session.cancellation.controller' => function ( $container ) : CancelController {
|
||||
return new CancelController(
|
||||
$container->get( 'session.handler' ),
|
||||
$container->get( 'session.cancellation.view' )
|
||||
|
|
|
@ -45,7 +45,7 @@ class SessionHandler {
|
|||
*
|
||||
* @return Order|null
|
||||
*/
|
||||
public function order() : ?Order {
|
||||
public function order() {
|
||||
return $this->order;
|
||||
}
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue