mirror of
https://github.com/woocommerce/woocommerce-paypal-payments.git
synced 2025-09-06 09:08:09 +08:00
Add compatibility module
This commit is contained in:
parent
bc5a84cdd2
commit
473463597a
4 changed files with 89 additions and 0 deletions
12
modules/ppcp-compat/extensions.php
Normal file
12
modules/ppcp-compat/extensions.php
Normal file
|
@ -0,0 +1,12 @@
|
|||
<?php
|
||||
/**
|
||||
* The compatibility module extensions.
|
||||
*
|
||||
* @package WooCommerce\PayPalCommerce\Compat
|
||||
*/
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace WooCommerce\PayPalCommerce\Compat;
|
||||
|
||||
return array();
|
16
modules/ppcp-compat/module.php
Normal file
16
modules/ppcp-compat/module.php
Normal file
|
@ -0,0 +1,16 @@
|
|||
<?php
|
||||
/**
|
||||
* The compatibility module.
|
||||
*
|
||||
* @package WooCommerce\PayPalCommerce\Compat
|
||||
*/
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace WooCommerce\PayPalCommerce\Compat;
|
||||
|
||||
use Dhii\Modular\Module\ModuleInterface;
|
||||
|
||||
return static function (): ModuleInterface {
|
||||
return new CompatModule();
|
||||
};
|
12
modules/ppcp-compat/services.php
Normal file
12
modules/ppcp-compat/services.php
Normal file
|
@ -0,0 +1,12 @@
|
|||
<?php
|
||||
/**
|
||||
* The compatibility module services.
|
||||
*
|
||||
* @package WooCommerce\PayPalCommerce\Compat
|
||||
*/
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace WooCommerce\PayPalCommerce\Compat;
|
||||
|
||||
return array();
|
49
modules/ppcp-compat/src/class-compatmodule.php
Normal file
49
modules/ppcp-compat/src/class-compatmodule.php
Normal file
|
@ -0,0 +1,49 @@
|
|||
<?php
|
||||
/**
|
||||
* The compatibility module.
|
||||
*
|
||||
* @package WooCommerce\PayPalCommerce\Compat
|
||||
*/
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace WooCommerce\PayPalCommerce\Compat;
|
||||
|
||||
use Dhii\Container\ServiceProvider;
|
||||
use Dhii\Modular\Module\ModuleInterface;
|
||||
use Interop\Container\ServiceProviderInterface;
|
||||
use Psr\Container\ContainerInterface;
|
||||
|
||||
/**
|
||||
* Class CompatModule
|
||||
*/
|
||||
class CompatModule implements ModuleInterface {
|
||||
|
||||
/**
|
||||
* Setup the compatibility module.
|
||||
*
|
||||
* @return ServiceProviderInterface
|
||||
*/
|
||||
public function setup(): ServiceProviderInterface {
|
||||
return new ServiceProvider(
|
||||
require __DIR__ . '/../services.php',
|
||||
require __DIR__ . '/../extensions.php'
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Run the compatibility module.
|
||||
*
|
||||
* @param ContainerInterface|null $container The Container.
|
||||
*/
|
||||
public function run( ContainerInterface $container ) {
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the key for the module.
|
||||
*
|
||||
* @return string|void
|
||||
*/
|
||||
public function getKey() {
|
||||
}
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue