| 1 |
<?php |
| 2 |
|
| 3 |
namespace Cookiez\Modules\Maxmind; |
| 4 |
|
| 5 |
use Cookiez\Classes\Module_Base; |
| 6 |
|
| 7 |
if ( ! defined( 'ABSPATH' ) ) { |
| 8 |
exit; // Exit if accessed directly. |
| 9 |
} |
| 10 |
|
| 11 |
/** |
| 12 |
* Module `Maxmind` |
| 13 |
* Owns the MaxMind GeoLite2 database download/update logic and the license |
| 14 |
* key storage/REST endpoint consumed by the Settings and Banner modules. |
| 15 |
*/ |
| 16 |
class Module extends Module_Base { |
| 17 |
public function get_name(): string { |
| 18 |
return 'Maxmind'; |
| 19 |
} |
| 20 |
|
| 21 |
public static function component_list(): array { |
| 22 |
return [ |
| 23 |
'Maxmind_Database_Updater', |
| 24 |
]; |
| 25 |
} |
| 26 |
|
| 27 |
public static function routes_list(): array { |
| 28 |
return [ |
| 29 |
'Update_Maxmind_License_Key', |
| 30 |
]; |
| 31 |
} |
| 32 |
|
| 33 |
public function __construct() { |
| 34 |
$this->register_components(); |
| 35 |
$this->register_routes(); |
| 36 |
} |
| 37 |
} |
| 38 |
|