Changed cron job code