Refactoring inc/cron.php for style and documentation