| Server IP : 216.238.66.20 / Your IP : 216.73.216.199 Web Server : nginx/1.30.4 System : Linux woropds 5.15.0-187-generic #197-Ubuntu SMP Fri Jul 17 19:17:01 UTC 2026 x86_64 User : root ( 0) PHP Version : 8.2.33 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : OFF | Perl : OFF | Python : OFF | Sudo : OFF | Pkexec : OFF Directory : /var/www/sweetheart.mx/htdocs/wp-content/plugins/backwpup/src/Beta/ |
Upload File : |
<?php
declare(strict_types=1);
namespace WPMedia\BackWPup\Beta;
use WPMedia\BackWPup\Dependencies\League\Container\ServiceProvider\AbstractServiceProvider;
use WPMedia\Beta\Optin;
use WPMedia\Beta\Beta;
class ServiceProvider extends AbstractServiceProvider {
/**
* Services provided by this provider
*
* @var array
*/
protected $provides = [
Optin::class,
Beta::class,
Subscriber::class,
];
/**
* Subscribers provided by this provider
*
* @var array
*/
public $subscribers = [
Subscriber::class,
];
/**
* Check if the service provider provides a specific service.
*
* @param string $id The id of the service.
*
* @return bool
*/
public function provides( string $id ): bool {
return in_array( $id, $this->provides, true );
}
/**
* Registers items with the container
*
* @return void
*/
public function register(): void {
$this->getContainer()->add( Optin::class )
->addArguments(
[
'backwpup',
'manage_options',
]
);
$this->getContainer()->add( Beta::class )
->addArguments(
[
Optin::class,
\BackWPup::get_plugin_data( 'basename' ),
'backwpup',
\BackWPup::get_plugin_data( 'version' ),
]
);
$this->getContainer()->add( Subscriber::class )
->addArguments(
[
Optin::class,
Beta::class,
'backwpup_adapter',
]
);
}
/**
* Returns the subscribers array
*
* @return array
*/
public function get_subscribers() {
return $this->subscribers;
}
}