You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is it possible to pass args to a function and replace '* * * * *' with those arguments? I'm trying
`var day = '';
var month = '';
var hour = '';
var min = '';
//these values will ultimately be something else obviously
function doJob(day, month, hour, min) {
var time = '' + min + ' ' + hour + ' ' + day + ' ' + month + ' *';
var cron = new Meteor.Cron({
events:{
time : test
}
});
return cron;
}`
but this doesn't work unfortunately. No errors, just no response from the cronjob i.e. it doesn't do anything.
The text was updated successfully, but these errors were encountered:
Is it possible to pass args to a function and replace '* * * * *' with those arguments? I'm trying
`var day = '';
var month = '';
var hour = '';
var min = '';
//these values will ultimately be something else obviously
function doJob(day, month, hour, min) {
var time = '' + min + ' ' + hour + ' ' + day + ' ' + month + ' *';
var cron = new Meteor.Cron({
events:{
time : test
}
});
return cron;
}`
but this doesn't work unfortunately. No errors, just no response from the cronjob i.e. it doesn't do anything.
The text was updated successfully, but these errors were encountered: