| Server IP : 35.236.43.222 / Your IP : 216.73.216.143 Web Server : Apache System : Linux order-form-vm-001 5.10.0-37-cloud-amd64 #1 SMP Debian 5.10.247-1 (2025-12-11) x86_64 User : deploy ( 1002) PHP Version : 8.1.31 Disable Function : NONE MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : OFF | Sudo : ON | Pkexec : OFF Directory : /var/www/mastersystem.app/public/wp-content/plugins/koko-analytics/src/ |
Upload File : |
<?php
namespace KokoAnalytics;
class Cron
{
public function setup()
{
if (! wp_next_scheduled('koko_analytics_aggregate_stats')) {
wp_schedule_event(time() + 60, 'koko_analytics_stats_aggregate_interval', 'koko_analytics_aggregate_stats');
}
if (! wp_next_scheduled('koko_analytics_prune_data')) {
wp_schedule_event(time() + DAY_IN_SECONDS, 'daily', 'koko_analytics_prune_data');
}
if (! wp_next_scheduled('koko_analytics_rotate_fingerprint_seed')) {
$time_next_midnight = (new \DateTimeImmutable('tomorrow, midnight', wp_timezone()))->getTimestamp();
wp_schedule_event($time_next_midnight, 'daily', 'koko_analytics_rotate_fingerprint_seed');
}
}
public function clear()
{
wp_clear_scheduled_hook('koko_analytics_aggregate_stats');
wp_clear_scheduled_hook('koko_analytics_prune_data');
wp_clear_scheduled_hook('koko_analytics_rotate_fingerprint_seed');
}
}