Fixed cron job bug