Files
pr-vision/includes/core/class-prv-activator.php
peptiderepo 7d254019c6 PHPCS: fix file docblock format (short description + blank line after)
File-level docblocks lacked a short description and required blank line
between the block and declare(strict_types=1). WP PHPCS file comment
sniff requires both. All 21 PHP files corrected.

Agent-Session: pr-vision rename v0.1.1
2026-06-13 09:46:19 +00:00

39 lines
926 B
PHP

<?php
/**
* Plugin activation handler.
*
* @package PrVision
*/
declare(strict_types=1);
/**
* Plugin activation handler.
*
* Creates the custom database table via dbDelta and registers the weekly
* WP-Cron probe schedule. Safe to call on re-activation — dbDelta is
* idempotent and the cron schedule is only added when absent.
*
* Who triggers: register_activation_hook() in pr-vision.php.
* Dependencies: PRV_Table_Manager, PRV_Cron, PRV_Config.
*
* @see class-prv-table-manager.php — Database schema creation.
* @see class-prv-cron.php — Cron scheduling.
* @package PrVision
*/
class PRV_Activator {
/**
* Run all activation tasks.
*
* Side effects: Creates DB table, writes default options, schedules cron.
*
* @return void
*/
public static function activate(): void {
PRV_Table_Manager::create_table();
PRV_Config::seed_defaults();
PRV_Cron::schedule_weekly();
}
}