introduced function to check cron job validation